Skip to content
Commit fe53fde7 authored by Matthew Barnes's avatar Matthew Barnes
Browse files

Add camel_imapx_command_add_qresync_parameter().

This splits a big wad of extra logic in imapx_select() out into a nice
and tidy utility function.

One important change, however, is the message sequence match data stops
at the lesser message count reported by the IMAP server vs. our summary.

This is to work around a frequent Zimbra IMAP failure where listing a
message sequence number in a QRESYNC parameter which exceeds the true
message count results in a so-called "parse error" from Zimbra:

   A00010 SELECT INBOX (QRESYNC (... (1,5,10 ...)))
   * 9 EXISTS
   ...
   A00010 BAD parse error: invalid message sequence number: 1,5,10

This scenario can happen if messages have been expunged from the
folder, but our summary has not yet been updated to reflect that.

Not sure if this is a Zimbra bug.  I certainly would not call it a
"parse error", but RFC 5162 is not clear on this detail.

(cherry picked from commit 89b3af25)
parent 1a0d5fec
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment