dovecot-1.2: mbox: Fixed assert-crash with pop3_lock_session=yes
dovecot at dovecot.org
dovecot at dovecot.org
Thu Jan 8 21:48:26 EET 2009
details: http://hg.dovecot.org/dovecot-1.2/rev/06c641b17175
changeset: 8602:06c641b17175
user: Timo Sirainen <tss at iki.fi>
date: Thu Jan 08 14:47:58 2009 -0500
description:
mbox: Fixed assert-crash with pop3_lock_session=yes
diffstat:
1 file changed, 6 insertions(+), 2 deletions(-)
src/lib-storage/index/mbox/mbox-transaction.c | 8 ++++++--
diffs (18 lines):
diff -r da02a1d15783 -r 06c641b17175 src/lib-storage/index/mbox/mbox-transaction.c
--- a/src/lib-storage/index/mbox/mbox-transaction.c Thu Jan 08 12:22:11 2009 -0500
+++ b/src/lib-storage/index/mbox/mbox-transaction.c Thu Jan 08 14:47:58 2009 -0500
@@ -50,8 +50,12 @@ static int mbox_transaction_commit(struc
if (mbox_unlock(mbox, lock_id) < 0)
ret = -1;
}
- i_assert(mbox->ibox.box.transaction_count > 0 ||
- mbox->mbox_lock_type == F_UNLCK);
+ if (mbox->mbox_global_lock_id == 0) {
+ i_assert(mbox->ibox.box.transaction_count > 0 ||
+ mbox->mbox_lock_type == F_UNLCK);
+ } else {
+ i_assert(mbox->mbox_lock_type == F_WRLCK);
+ }
return ret;
}
More information about the dovecot-cvs
mailing list