dovecot-2.0: maildir + pop3_lock_session: Don't crash when openi...
dovecot at dovecot.org
dovecot at dovecot.org
Wed Jan 20 11:27:45 EET 2010
details: http://hg.dovecot.org/dovecot-2.0/rev/32d6a4112147
changeset: 10565:32d6a4112147
user: Timo Sirainen <tss at iki.fi>
date: Wed Jan 20 11:27:38 2010 +0200
description:
maildir + pop3_lock_session: Don't crash when opening mailbox causes uidlist rewrite.
diffstat:
1 file changed, 5 insertions(+)
src/lib-storage/index/maildir/maildir-uidlist.c | 5 +++++
diffs (15 lines):
diff -r 69c793c7f185 -r 32d6a4112147 src/lib-storage/index/maildir/maildir-uidlist.c
--- a/src/lib-storage/index/maildir/maildir-uidlist.c Tue Jan 19 22:01:18 2010 +0200
+++ b/src/lib-storage/index/maildir/maildir-uidlist.c Wed Jan 20 11:27:38 2010 +0200
@@ -1314,6 +1314,11 @@ maildir_uidlist_records_drop_expunges(st
unsigned int i, count;
uint32_t seq;
+ /* we could get here when opening and locking mailbox,
+ before index files have been opened. */
+ if (!uidlist->mbox->ibox.box.opened)
+ return;
+
mail_index_refresh(uidlist->mbox->ibox.index);
view = mail_index_view_open(uidlist->mbox->ibox.index);
count = array_count(&uidlist->records);
More information about the dovecot-cvs
mailing list