[dovecot-cvs] dovecot/src/lib-storage/index/maildir maildir-uidlist.c, 1.65, 1.66
tss at dovecot.org
tss at dovecot.org
Wed May 9 16:12:15 EEST 2007
Update of /var/lib/cvs/dovecot/src/lib-storage/index/maildir
In directory talvi:/tmp/cvs-serv29790
Modified Files:
maildir-uidlist.c
Log Message:
Make sure uid_validity and next_uid aren't 0 in the uidlist header.
Index: maildir-uidlist.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/maildir/maildir-uidlist.c,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -d -r1.65 -r1.66
--- maildir-uidlist.c 30 Mar 2007 12:44:03 -0000 1.65
+++ maildir-uidlist.c 9 May 2007 13:12:13 -0000 1.66
@@ -347,6 +347,11 @@
"%s: next_uid was lowered (%u -> %u)",
uidlist->fname, uidlist->next_uid, next_uid);
ret = 0;
+ } else if (uid_validity == 0 || next_uid == 0) {
+ mail_storage_set_critical(storage,
+ "%s: Broken header (uidvalidity = %u, next_uid=%u)",
+ uidlist->fname, uid_validity, next_uid);
+ ret = 0;
} else {
uidlist->uid_validity = uid_validity;
uidlist->next_uid = next_uid;
More information about the dovecot-cvs
mailing list