]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
mbox: Previous change broke index updates to successful saves.
authorTimo Sirainen <tss@iki.fi>
Sun, 19 May 2013 20:21:20 +0000 (23:21 +0300)
committerTimo Sirainen <tss@iki.fi>
Sun, 19 May 2013 20:21:20 +0000 (23:21 +0300)
src/lib-storage/index/mbox/mbox-save.c

index 218f29079643502c2cb844cddab3f1a04c3ec1c5..5f2ec0c32808cb60820470a98647cd9e22ebe258 100644 (file)
@@ -715,7 +715,7 @@ int mbox_save_finish(struct mail_save_context *_ctx)
                ctx->mail_offset = (uoff_t)-1;
        }
 
-       if (ctx->seq != 0) {
+       if (ctx->seq != 0 && ctx->failed) {
                mail_index_expunge(ctx->trans, ctx->seq);
                /* currently we can't just drop pending cache updates for this
                   one specific record, so we'll reset the whole cache