[dovecot-cvs] dovecot/src/lib-storage/index/mbox mbox-sync.c, 1.80, 1.81

cras at dovecot.org cras at dovecot.org
Sat Sep 11 13:00:53 EEST 2004


Update of /var/lib/cvs/dovecot/src/lib-storage/index/mbox
In directory talvi:/tmp/cvs-serv5715/lib-storage/index/mbox

Modified Files:
	mbox-sync.c 
Log Message:
When there's nothing to do to sync mbox, still commit index syncing instead
of rollbacking because it may need to sync index internally.



Index: mbox-sync.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-sync.c,v
retrieving revision 1.80
retrieving revision 1.81
diff -u -d -r1.80 -r1.81
--- mbox-sync.c	10 Sep 2004 12:22:23 -0000	1.80
+++ mbox-sync.c	11 Sep 2004 10:00:50 -0000	1.81
@@ -1187,7 +1187,13 @@
 		/* nothing to do */
 		if (lock_id != 0)
 			(void)mbox_unlock(ibox, lock_id);
-		mail_index_sync_rollback(index_sync_ctx);
+
+		/* index may need to do internal syncing though, so commit
+		   instead of rollbacking. */
+		if (mail_index_sync_commit(index_sync_ctx) < 0) {
+			mail_storage_set_index_error(ibox);
+			return -1;
+		}
 		return 0;
 	}
 



More information about the dovecot-cvs mailing list