X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=imap%2Fimap.c;h=76d9f8b1a4e35996cdef5ad2f36a3220dfcf9f5b;hp=110486e430f15d0bcb4d222f9d50b4bd7a6aeb94;hb=debd2491451020d9fd5f0440bb2dada0b9eac6e7;hpb=3f3ce3e32da45b2626dfa40a994cb37ca4021e5b diff --git a/imap/imap.c b/imap/imap.c index 110486e..76d9f8b 100644 --- a/imap/imap.c +++ b/imap/imap.c @@ -1017,7 +1017,7 @@ int imap_sync_mailbox (CONTEXT * ctx, int expunge, int *index_hint) /* if the message has been rethreaded or attachments have been deleted * we delete the message and reupload it. * This works better if we're expunging, of course. */ - if (ctx->hdrs[n]->refs_changed || ctx->hdrs[n]->irt_changed || + if ((ctx->hdrs[n]->env && (ctx->hdrs[n]->env->refs_changed || ctx->hdrs[n]->env->irt_changed)) || ctx->hdrs[n]->attach_del) { debug_print (3, ("Attachments to be deleted, falling back to _mutt_save_message\n")); if (!appendctx)