hiciu/gmail-sync-labels — pull request #2 by fastcat (2013-11-12 16:21:58+00:00)
Title: Improved handling of non-ideal messages, handle message header encoding

Here is more work I've added. The older commits are mainly about managing degenerate cases and gracefully handling semi-invalid data.

The latest commit is to deal with a change in the GMail IMAP interface, where many GMail-added message headers are now put in UTF-8 encoding (e.g. "=?utf-8?q?blahblahblah?=") even if their values are entirely ASCII. This was breaking some of the message indexing.