From 8137e53c14cd09e495153c9b8d2989681e3b71b6 Mon Sep 17 00:00:00 2001 From: John Goerzen Date: Tue, 16 Nov 2004 23:41:09 +0100 Subject: [PATCH] Added code to limit command line length for very large mailboxes Keywords: (jgoerzen@complete.org--projects/offlineimap--head--1.0--patch-4) --- ChangeLog | 12 ++++++++++++ offlineimap/folder/IMAP.py | 6 ++++++ 2 files changed, 18 insertions(+) diff --git a/ChangeLog b/ChangeLog index f283e57..948c0b7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,18 @@ # arch-tag: automatic-ChangeLog--jgoerzen@complete.org--projects/offlineimap--head--1.0 # +2004-11-16 16:41:09 GMT John Goerzen patch-4 + + Summary: + Added code to limit command line length for very large mailboxes + Revision: + offlineimap--head--1.0--patch-4 + + + modified files: + ChangeLog offlineimap/folder/IMAP.py + + 2004-10-18 14:01:50 GMT John Goerzen patch-3 Summary: diff --git a/offlineimap/folder/IMAP.py b/offlineimap/folder/IMAP.py index e18cb51..93f83f4 100644 --- a/offlineimap/folder/IMAP.py +++ b/offlineimap/folder/IMAP.py @@ -282,6 +282,12 @@ class IMAPFolder(BaseFolder): self.processmessagesflags('-', uidlist, flags) def processmessagesflags(self, operation, uidlist, flags): + if len(uidlist) > 101: + # Hack for those IMAP ervers with a limited line length + self.processmessagesflags(operation, uidlist[:100], flags) + self.processmessagesflags(operation, uidlist[100:], flags) + return + imapobj = self.imapserver.acquireconnection() try: try: -- 2.39.2