From 50d46631b6c27e0dfaf47b1a59365ce9b4b152ec Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Sat, 19 Dec 2015 18:05:36 +0100 Subject: Avoid starting resources on non-live queries. --- common/queryrunner.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'common') diff --git a/common/queryrunner.cpp b/common/queryrunner.cpp index 25570bc..718586f 100644 --- a/common/queryrunner.cpp +++ b/common/queryrunner.cpp @@ -65,7 +65,10 @@ QueryRunner::QueryRunner(const Akonadi2::Query &query, const Akonadi mResultProvider->setFetcher([this, query](const typename DomainType::Ptr &parent) { Trace() << "Running fetcher"; const qint64 newRevision = executeInitialQuery(query, parent, *mResultProvider); - mResourceAccess->sendRevisionReplayedCommand(newRevision); + //Only send the revision replayed information if we're connected to the resource, there's no need to start the resource otherwise. + if (query.liveQuery) { + mResourceAccess->sendRevisionReplayedCommand(newRevision); + } }); -- cgit v1.2.3