From e2af591e891683fe4199cd2b1b2ab0e5eef3a392 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luis=20=C3=81ngel=20San=20Mart=C3=ADn?= Date: Thu, 19 Mar 2015 22:11:26 +0100 Subject: [PATCH] merged --- compressed_archive/compressed_archive.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/compressed_archive/compressed_archive.cpp b/compressed_archive/compressed_archive.cpp index 25bcc2ee..797bb644 100644 --- a/compressed_archive/compressed_archive.cpp +++ b/compressed_archive/compressed_archive.cpp @@ -178,12 +178,16 @@ CompressedArchive::CompressedArchive(const QString & filePath, QObject *parent) CompressedArchive::~CompressedArchive() { + #ifdef Q_OS_UNIX if(isRar) //TODO: fix this!!! Possible memory leak. If AddRef is not used, a crash occurs in "delete szInterface" szInterface->archive->AddRef(); #endif if(valid) //TODO: fix this!!! Memory leak. + { + szInterface->archive->Close(); delete szInterface; + } #ifdef Q_OS_UNIX delete rarLib; #endif