changeset 5265:d7bd3f80c6f2 HEAD

After saving mails we didn't update last-uid header in X-IMAP[base] if lazy writes were used.
author Timo Sirainen <tss@iki.fi>
date Sat, 10 Mar 2007 17:47:32 +0200
parents 169b5e67d307
children 0dc6b54bb6aa
files src/lib-storage/index/mbox/mbox-transaction.c
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-storage/index/mbox/mbox-transaction.c	Sat Mar 10 17:46:44 2007 +0200
+++ b/src/lib-storage/index/mbox/mbox-transaction.c	Sat Mar 10 17:47:32 2007 +0200
@@ -49,8 +49,10 @@
 			mbox_sync_flags |= MBOX_SYNC_UNDIRTY;
 		if ((flags & MAILBOX_SYNC_FLAG_FULL_WRITE) != 0)
 			mbox_sync_flags |= MBOX_SYNC_REWRITE;
-		if (mbox_modified)
-			mbox_sync_flags |= MBOX_SYNC_HEADER;
+		if (mbox_modified) {
+			/* after saving mails we want to update the last-uid */
+			mbox_sync_flags |= MBOX_SYNC_HEADER | MBOX_SYNC_REWRITE;
+		}
 		if (mbox_sync(mbox, mbox_sync_flags) < 0)
 			ret = -1;
 	}