[PATCH] folder: Maildir: add comments about FMD5 issues

Nicolas Sebrecht nicolas.s-dev at laposte.net
Wed Jun 29 00:54:06 BST 2016


Signed-off-by: Nicolas Sebrecht <nicolas.s-dev at laposte.net>
---

The following changes since commit 3293b75c9c735f054eb267afcc6f3f9713e6c1aa:

  release.sh: get_git_who(): remove unnecessary blank line (2016-06-27 16:11:44 +0200)

are available in the git repository at:

  https://github.com/nicolas33/offlineimap.git ns/fmd5

for you to fetch changes up to 591bb92dcdf1e9548ba7feea1fdc8b532151726d:

  folder: Maildir: add comments about FMD5 issues (2016-06-29 01:51:40 +0200)

----------------------------------------------------------------

 offlineimap/folder/Maildir.py | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/offlineimap/folder/Maildir.py b/offlineimap/folder/Maildir.py
index f5b208c..91af24a 100644
--- a/offlineimap/folder/Maildir.py
+++ b/offlineimap/folder/Maildir.py
@@ -135,6 +135,13 @@ class MaildirFolder(BaseFolder):
         foldermatch = folderstr in filename
         # If there was no folder MD5 specified, or if it mismatches,
         # assume it is a foreign (new) message and ret: uid, fmd5 = None, None
+
+        # XXX: This is wrong behaviour: if FMD5 is missing or mismatches, assume
+        # the mail is new and **fix UID to None** to avoid any conflict.
+
+        # XXX: If UID is missing, I have no idea what FMD5 can do. Should be
+        # fixed to None in this case, too.
+
         if foldermatch:
             uidmatch = re_uidmatch.search(filename)
             if uidmatch:
-- 
2.7.4




More information about the OfflineIMAP-project mailing list