Mercurial > dovecot > core-2.2
changeset 5102:f8c2cf9e3267 HEAD
Commit the transaction even if client didn't QUIT so cached data gets saved.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Mon, 05 Feb 2007 13:42:50 +0200 |
parents | deb7c9e2406a |
children | 050549cfaa25 |
files | src/pop3/client.c |
diffstat | 1 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/pop3/client.c Mon Feb 05 13:27:11 2007 +0200 +++ b/src/pop3/client.c Mon Feb 05 13:42:50 2007 +0200 @@ -226,8 +226,12 @@ client->cmd(client); i_assert(client->cmd == NULL); } - if (client->trans != NULL) - mailbox_transaction_rollback(&client->trans); + if (client->trans != NULL) { + /* client didn't QUIT, but we still want to save any changes + done in this transaction. especially the cached virtual + message sizes. */ + (void)mailbox_transaction_commit(&client->trans, 0); + } if (client->mailbox != NULL) mailbox_close(&client->mailbox); mail_storage_destroy(&client->storage);