dovecot-1.1: Avoid assert-crashing when two processes try to cre...
dovecot at dovecot.org
dovecot at dovecot.org
Wed Sep 30 18:08:41 EEST 2009
details: http://hg.dovecot.org/dovecot-1.1/rev/d551cd628efa
changeset: 8356:d551cd628efa
user: Timo Sirainen <tss at iki.fi>
date: Wed Sep 30 11:08:18 2009 -0400
description:
Avoid assert-crashing when two processes try to create index at the same time.
diffstat:
1 file changed, 5 insertions(+)
src/lib-index/mail-index.c | 5 +++++
diffs (15 lines):
diff -r 298d58ab6e2c -r d551cd628efa src/lib-index/mail-index.c
--- a/src/lib-index/mail-index.c Wed Sep 30 08:52:12 2009 -0400
+++ b/src/lib-index/mail-index.c Wed Sep 30 11:08:18 2009 -0400
@@ -347,6 +347,11 @@ static int mail_index_open_files(struct
}
ret = mail_transaction_log_create(index->log, FALSE);
+ if (index->map != NULL) {
+ /* log creation could have changed it if someone else
+ just created it. */
+ index->map->hdr.indexid = index->indexid;
+ }
index->initial_create = FALSE;
created = TRUE;
}
More information about the dovecot-cvs
mailing list