changeset 5761:8008fbb660c1 HEAD

Even if mailbox sync fails, commit the transaction so that cache file gets updated.
author Timo Sirainen <tss@iki.fi>
date Sun, 17 Jun 2007 22:08:50 +0300
parents 7851879631ea
children 9e762641180d
files src/pop3/client.c
diffstat 1 files changed, 4 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/pop3/client.c	Sun Jun 17 22:01:16 2007 +0300
+++ b/src/pop3/client.c	Sun Jun 17 22:08:50 2007 +0300
@@ -101,7 +101,7 @@
 		mail_free(&mail);
 		if (mailbox_search_deinit(&ctx) < 0) {
 			client_send_storage_error(client);
-			mailbox_transaction_rollback(&t);
+			(void)mailbox_transaction_commit(&t, 0);
 			break;
 		}
 
@@ -112,8 +112,9 @@
 			return TRUE;
 		}
 
-		/* well, sync and try again */
-		mailbox_transaction_rollback(&t);
+		/* well, sync and try again. we might have cached virtual
+		   sizes, make sure they get committed. */
+		(void)mailbox_transaction_commit(&t, 0);
 	}
 
 	if (i == 2)