From: Timo Sirainen Date: Sun, 20 May 2018 12:55:03 +0000 (+0300) Subject: lib-index: fsck: Don't change log_file_tail_offset=0 X-Git-Tag: 2.3.9~1840 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=308048a191425b7a8113414040bc5a3169867def;p=thirdparty%2Fdovecot%2Fcore.git lib-index: fsck: Don't change log_file_tail_offset=0 --- diff --git a/src/lib-index/mail-index-fsck.c b/src/lib-index/mail-index-fsck.c index c58c06befd..e4d5f4a8d3 100644 --- a/src/lib-index/mail-index-fsck.c +++ b/src/lib-index/mail-index-fsck.c @@ -47,7 +47,8 @@ mail_index_fsck_log_pos(struct mail_index *index, struct mail_index_map *map, if (hdr->log_file_tail_offset > hdr->log_file_head_offset) hdr->log_file_tail_offset = hdr->log_file_head_offset; - else if (hdr->log_file_tail_offset < MAIL_TRANSACTION_LOG_HEADER_MIN_SIZE) + else if (hdr->log_file_tail_offset != 0 && + hdr->log_file_tail_offset < MAIL_TRANSACTION_LOG_HEADER_MIN_SIZE) hdr->log_file_tail_offset = MAIL_TRANSACTION_LOG_HEADER_MIN_SIZE; } else { /* index's log_file_seq is newer than exists. move it to