Branch 'kolab/integration/4.13.0' - resources/kolab
Christian Mollekopf
mollekopf at kolabsys.com
Mon Oct 6 09:45:43 CEST 2014
resources/kolab/kolabretrievetagstask.cpp | 6 ++++++
1 file changed, 6 insertions(+)
New commits:
commit ff160eb624253c9e1a11d916eca08cd228bbb5e5
Author: Christian Mollekopf <chrigi_1 at fastmail.fm>
Date: Mon Oct 6 09:45:19 2014 +0200
KolabRetrieveTagsTask: Don't try to retrieve tags if no messages are available.
Otherwise we get an error.
diff --git a/resources/kolab/kolabretrievetagstask.cpp b/resources/kolab/kolabretrievetagstask.cpp
index 8a04d09..9b17355 100644
--- a/resources/kolab/kolabretrievetagstask.cpp
+++ b/resources/kolab/kolabretrievetagstask.cpp
@@ -54,6 +54,12 @@ void KolabRetrieveTagTask::onFinalSelectDone(KJob *job)
KIMAP::SelectJob *select = static_cast<KIMAP::SelectJob*>(job);
KIMAP::FetchJob *fetch = new KIMAP::FetchJob(select->session());
+ if (select->messageCount() == 0) {
+ //Nothing to do
+ taskDone();
+ return;
+ }
+
KIMAP::ImapSet set;
set.add(KIMAP::ImapInterval(1, 0));
fetch->setSequenceSet(set);
More information about the commits
mailing list