dovecot-2.0: lib-index: On errors, close sync view before fsck t...

dovecot at dovecot.org dovecot at dovecot.org
Tue May 25 17:27:32 EEST 2010


details:   http://hg.dovecot.org/dovecot-2.0/rev/b08abace44ed
changeset: 11363:b08abace44ed
user:      Timo Sirainen <tss at iki.fi>
date:      Tue May 25 15:25:01 2010 +0100
description:
lib-index: On errors, close sync view before fsck to avoid assert-crash.

diffstat:

 src/lib-index/mail-index-sync-update.c |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (17 lines):

diff -r d285a4ee07c4 -r b08abace44ed src/lib-index/mail-index-sync-update.c
--- a/src/lib-index/mail-index-sync-update.c	Tue May 25 15:24:05 2010 +0100
+++ b/src/lib-index/mail-index-sync-update.c	Tue May 25 15:25:01 2010 +0100
@@ -959,12 +959,12 @@
 					    map->hdr.log_file_seq, start_offset,
 					    (uint32_t)-1, (uoff_t)-1, &reset);
 	if (ret <= 0) {
+		mail_index_view_close(&view);
 		if (force && ret == 0) {
 			/* the seq/offset is probably broken */
 			(void)mail_index_fsck(index);
 		}
 		/* can't use it. sync by re-reading index. */
-		mail_index_view_close(&view);
 		return 0;
 	}
 


More information about the dovecot-cvs mailing list