]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-index: Try to avoid duplicate "duplicate transaction log sequence" errors.
authorTimo Sirainen <tss@iki.fi>
Tue, 3 May 2011 07:58:11 +0000 (09:58 +0200)
committerTimo Sirainen <tss@iki.fi>
Tue, 3 May 2011 07:58:11 +0000 (09:58 +0200)
src/lib-index/mail-transaction-log-file.c

index da990d07ebc67c9c43e05ef76af674c919afe818..f1f11ab922e4b1b2f70d9d9bd9d37e55f5bdbda8 100644 (file)
@@ -527,7 +527,7 @@ mail_transaction_log_file_read_hdr(struct mail_transaction_log_file *file,
           opened. it shouldn't happen unless the old log file was
           corrupted. */
        for (f = file->log->files; f != NULL; f = f->next) {
-               if (f->hdr.file_seq == file->hdr.file_seq) {
+               if (f->hdr.file_seq == file->hdr.file_seq && !f->corrupted) {
                        /* mark the old file corrupted. we can't safely remove
                           it from the list however, so return failure. */
                        f->corrupted = TRUE;