[dovecot-cvs] dovecot/src/lib-index mail-index.c,1.179,1.180

cras at dovecot.org cras at dovecot.org
Sun Dec 5 03:49:23 EET 2004


Update of /var/lib/cvs/dovecot/src/lib-index
In directory talvi:/tmp/cvs-serv16771/lib-index

Modified Files:
	mail-index.c 
Log Message:
mmap_disable=yes: if mail_index_map() is called while syncing make sure we
don't read past what is already synced into index.



Index: mail-index.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-index/mail-index.c,v
retrieving revision 1.179
retrieving revision 1.180
diff -u -d -r1.179 -r1.180
--- mail-index.c	5 Dec 2004 01:47:03 -0000	1.179
+++ mail-index.c	5 Dec 2004 01:49:20 -0000	1.180
@@ -655,6 +655,12 @@
 	unsigned int i;
 	int ret, retry;
 
+	if (index->log_locked) {
+		/* we're most likely syncing the index and we really don't
+		   want to read more than what was synced last time. */
+		sync_to_index = TRUE;
+	}
+
 	if ((*map)->hdr.indexid != 0) {
 		/* sync this as a view from transaction log. */
 		index->sync_update = TRUE;



More information about the dovecot-cvs mailing list