From 2213c2e77b9b0776b79f1b76bffd8b9494df87f2 Mon Sep 17 00:00:00 2001 From: "Aaron J. Seigo" Date: Tue, 4 May 2010 03:28:09 +0000 Subject: [PATCH] a little more conservative svn path=/trunk/KDE/kdelibs/; revision=1122507 --- dataengine.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dataengine.cpp b/dataengine.cpp index 1e5eea040..c2488ec67 100644 --- a/dataengine.cpp +++ b/dataengine.cpp @@ -341,9 +341,11 @@ void DataEngine::removeAllSources() QMutableHashIterator it(d->sources); while (it.hasNext()) { it.next(); - emit sourceRemoved(it.key()); - delete it.value(); + const QString source = it.key(); + Plasma::DataContainer *s = it.value(); it.remove(); + emit sourceRemoved(source); + delete s; } }