summaryrefslogtreecommitdiffstats
path: root/src/gui/dialogs
diff options
context:
space:
mode:
authormread <qt-info@nokia.com>2011-07-28 13:22:02 (GMT)
committermread <qt-info@nokia.com>2011-07-28 13:22:02 (GMT)
commit57179745d245529b23ef2088012ecc3fde6e15ba (patch)
tree9e55c36374921a6738cec74d5adeb53a927e8a6b /src/gui/dialogs
parent5679d966b396523a1d555a4029e7da05515be2fa (diff)
downloadQt-57179745d245529b23ef2088012ecc3fde6e15ba.zip
Qt-57179745d245529b23ef2088012ecc3fde6e15ba.tar.gz
Qt-57179745d245529b23ef2088012ecc3fde6e15ba.tar.bz2
Memory leak fix in Symbian open file dialog
Symbian open file dialog was using a filter but not deleting it. Task-number: QTBUG-20357 Reviewed-by: Laszlo Agocs
Diffstat (limited to 'src/gui/dialogs')
-rw-r--r--src/gui/dialogs/qfiledialog_symbian.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/dialogs/qfiledialog_symbian.cpp b/src/gui/dialogs/qfiledialog_symbian.cpp
index 16ef5b6..cd020f6 100644
--- a/src/gui/dialogs/qfiledialog_symbian.cpp
+++ b/src/gui/dialogs/qfiledialog_symbian.cpp
@@ -59,7 +59,7 @@ extern QStringList qt_clean_filter_list(const QString &filter); // defined in qf
enum DialogMode { DialogOpen, DialogSave, DialogFolder };
#if defined(Q_WS_S60) && !defined(SYMBIAN_VERSION_9_4)
-class CExtensionFilter : public MAknFileFilter
+class CExtensionFilter : public CBase, public MAknFileFilter
{
public:
void setFilter(const QString filter)
@@ -127,7 +127,7 @@ static QString launchSymbianDialog(const QString dialogCaption, const QString st
extensionFilter->setFilter(filter);
select = AknCommonDialogsDynMem::RunSelectDlgLD(types, target,
startFolder, 0, 0, titlePtr, extensionFilter);
- CleanupStack::Pop(extensionFilter);
+ CleanupStack::PopAndDestroy(extensionFilter);
} else if (dialogMode == DialogSave) {
QString defaultFileName = QFileDialogPrivate::initialSelection(startDirectory);
target = qt_QString2TPtrC(defaultFileName);