IMAP: fixed message flags retrieval, which failed to extract the right string

from the server response.  Tough.
This commit is contained in:
Nikolaus Schulz 2007-11-02 12:00:12 +00:00
parent 6ea7c7d810
commit 82e3be1987
1 changed files with 1 additions and 1 deletions

View File

@ -1383,7 +1383,7 @@ def _archive_imap(mailbox_name, final_archive_name):
msg_str = response[0][1]
else:
msg_str = response[0][1].replace("\r\n", os.linesep)
msg_flags = imaplib.ParseFlags(response[1])
msg_flags = imaplib.ParseFlags(response[0][0])
msg = rfc822.Message(cStringIO.StringIO(msg_str))
add_status_headers_imap(msg, msg_flags)
vprint("processing message '%s'" % msg.get('Message-ID'))