summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mail/changes/bug_dont_fail_on_emtpy_mail2
-rw-r--r--mail/src/leap/mail/imap/fetch.py3
2 files changed, 3 insertions, 2 deletions
diff --git a/mail/changes/bug_dont_fail_on_emtpy_mail b/mail/changes/bug_dont_fail_on_emtpy_mail
new file mode 100644
index 00000000..0fc4ffc8
--- /dev/null
+++ b/mail/changes/bug_dont_fail_on_emtpy_mail
@@ -0,0 +1,2 @@
+ o Do not fail while processing an empty mail, just skip it. Fixes
+ #3457. \ No newline at end of file
diff --git a/mail/src/leap/mail/imap/fetch.py b/mail/src/leap/mail/imap/fetch.py
index ff6005d6..3b15c6a1 100644
--- a/mail/src/leap/mail/imap/fetch.py
+++ b/mail/src/leap/mail/imap/fetch.py
@@ -164,8 +164,7 @@ class LeapIncomingMail(object):
# XXX should check for _enc_scheme == "pubkey" || "none"
# that is what incoming mail uses.
encdata = doc.content[self.ENC_JSON_KEY]
- d = defer.Deferred(self._decrypt_msg(doc, encdata))
- d.addCallbacks(self._process_decrypted, log.msg)
+ defer.Deferred(self._decrypt_msg(doc, encdata))
else:
logger.debug('This does not look like a proper msg.')