aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Vrátil <dvratil@kde.org>2016-08-16 23:54:39 (GMT)
committerDaniel Vrátil <dvratil@kde.org>2016-08-16 23:56:57 (GMT)
commit5bd20653b8dc9db40a008f571c49d539caea4713 (patch)
treeb7709f331c5bada9349a97f0ae88c60424d100e2
parent0149865f90d31af471c20c7f25ffe3fe0d8fe8f4 (diff)
FakeAkonadiServer: delete old NotificationCollector in correct thread
NotificationCollector lives in Connection's thread, so we can delete it directly from FakeAkonadiServer's thread, use deferred deletion instead.
-rw-r--r--autotests/server/fakeakonadiserver.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/autotests/server/fakeakonadiserver.cpp b/autotests/server/fakeakonadiserver.cpp
index 9ac4f8b..1b3ccae 100644
--- a/autotests/server/fakeakonadiserver.cpp
+++ b/autotests/server/fakeakonadiserver.cpp
@@ -284,7 +284,8 @@ void FakeAkonadiServer::newCmdConnection(quintptr socketDescriptor)
{
mConnection = new FakeConnection(socketDescriptor);
delete mNotificationSpy;
- delete mNtfCollector;
+ // Delete collection in its own thread
+ mNtfCollector->deleteLater();
// Connection is it's own thread, so we have to make sure we get collector
// from DataStore of the Connection's thread, not ours