]> git.ipfire.org Git - thirdparty/dovecot/core.git/commit
lib-index: Fix detecting if index is undeleted
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Mon, 2 Nov 2020 16:55:16 +0000 (18:55 +0200)
committerTimo Sirainen <timo.sirainen@open-xchange.com>
Tue, 10 Nov 2020 15:24:01 +0000 (17:24 +0200)
commit68380ecde9292c1e9b1c4ced7221b9b7beb193c5
treeb85bcbf29339ea574acff3a948965bc58b8fbae4
parentc2122e0063761cbaf33a76c27c1b7de963e0ca8f
lib-index: Fix detecting if index is undeleted

It was possible that mail_index_is_deleted() kept returning that the index
was deleted, even if it was marked as undeleted. This happened when the
deletion was in dovecot.index.log.2, undeletion in dovecot.index.log and
dovecot.index pointed to the .log.2 file. This caused the .log file to be
read first, which sees the undeletion. Later on the .log.2 was parsed and
it marked the index back as deleted.
src/lib-index/mail-index-private.h
src/lib-index/mail-transaction-log-file.c