[dovecot-cvs] dovecot/src/lib-storage/index/maildir maildir-uidlist.c, 1.67, 1.68

tss at dovecot.org tss at dovecot.org
Wed May 16 16:31:16 EEST 2007


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

Modified Files:
	maildir-uidlist.c 
Log Message:
When recreating dovecot-uidlist file based on dovecot.index, we set next_uid
value wrong if new messages had been added.



Index: maildir-uidlist.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/maildir/maildir-uidlist.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -d -r1.67 -r1.68
--- maildir-uidlist.c	13 May 2007 17:10:52 -0000	1.67
+++ maildir-uidlist.c	16 May 2007 13:31:13 -0000	1.68
@@ -547,7 +547,8 @@
 				      uint32_t uid_validity, uint32_t next_uid)
 {
 	uidlist->uid_validity = uid_validity;
-	if (next_uid != 0)
+	/* set next_uid only if we know newer UIDs haven't been added yet */
+	if (uidlist->next_uid < next_uid)
 		uidlist->next_uid = next_uid;
 }
 



More information about the dovecot-cvs mailing list