Catch possible NPE in IMAP sync.

I don't know the root cause of the null pointer (possibly a broken
connection earlier in the sync) but we shouldn't be crashing here.

Fixes http://b/2135743
1 file changed