The EXPUNGE may have been sent while imapc_sync_index() was issuing
remote imapc commands. It would end up being in delayed_expunged_uids,
so the assert needs to check that too.
Fixes:
Panic: file imapc-sync.c: line 290 (imapc_initial_sync_check): assertion failed: (mail_index_is_expunged(view, lseq))
break;
}
/* it's already expunged and we should have marked it */
- i_assert(mail_index_is_expunged(view, lseq));
+ i_assert(mail_index_is_expunged(view, lseq) ||
+ seq_range_exists(&ctx->mbox->delayed_expunged_uids, luid));
lseq++;
} else {
/* message doesn't exist in index, but exists in