summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Riddell <jr@jriddell.org>2016-09-26 12:50:25 (GMT)
committerJonathan Riddell <jr@jriddell.org>2016-09-26 12:50:25 (GMT)
commit8ec1016e439f64a2d4ca57dd7ee73420651ca52b (patch)
tree49c3568999d496b0499a0fc5a1b103c0b8984c68
parent6b62563b44f252e168e6a3923e0d958ea747b32d (diff)
make appstream database on stack rather than leak
-rw-r--r--app/kipiinterface.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/kipiinterface.cpp b/app/kipiinterface.cpp
index 4a7da9d..a5cd2c4 100644
--- a/app/kipiinterface.cpp
+++ b/app/kipiinterface.cpp
@@ -357,9 +357,9 @@ void KIPIInterface::slotInstallPlugins(bool checked) {
d->installDialog = new QProgressDialog(i18n("Installing Plugins..."), i18n("Cancel"), 0, 0);
d->installDialog->setWindowModality(Qt::WindowModal);
- Appstream::Database* appstreamDatabase = new Appstream::Database();
- appstreamDatabase->open();
- Appstream::Component kipiPlugins = appstreamDatabase->componentById("photolayoutseditor.desktop");
+ Appstream::Database appstreamDatabase;
+ appstreamDatabase.open();
+ Appstream::Component kipiPlugins = appstreamDatabase.componentById("photolayoutseditor.desktop");
qDebug() << "The Package: " << kipiPlugins.packageNames()[0] << endl;
QString package = kipiPlugins.packageNames()[0];