summaryrefslogtreecommitdiff
path: root/src/settings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/settings.cpp')
-rw-r--r--src/settings.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/settings.cpp b/src/settings.cpp
index bf1f2e38..d3da6dbc 100644
--- a/src/settings.cpp
+++ b/src/settings.cpp
@@ -51,6 +51,7 @@
#include <KUrl>
// Qt Includes
+#include <QtCore/QPointer>
#include <QtGui/QWidget>
@@ -190,15 +191,17 @@ void SettingsDialog::saveSettings()
void SettingsDialog::showCookies()
{
- CookiesDialog *dialog = new CookiesDialog(Application::cookieJar(), this);
+ QPointer<CookiesDialog> dialog = new CookiesDialog(Application::cookieJar(), this);
dialog->exec();
+ delete dialog;
}
void SettingsDialog::showExceptions()
{
- CookiesExceptionsDialog *dialog = new CookiesExceptionsDialog(Application::cookieJar(), this);
+ QPointer<CookiesExceptionsDialog> dialog = new CookiesExceptionsDialog(Application::cookieJar(), this);
dialog->exec();
+ delete dialog;
}