[dovecot-cvs] dovecot/src/pop3 commands.c,1.53.2.4,1.53.2.5
tss at dovecot.org
tss at dovecot.org
Thu Feb 15 12:12:55 UTC 2007
Update of /var/lib/cvs/dovecot/src/pop3
In directory talvi:/tmp/cvs-serv21597
Modified Files:
Tag: branch_1_0
commands.c
Log Message:
RSET: Don't rollback the transaction if LAST is enabled (there's no point,
because all the seen flags are removed anyway).
Index: commands.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/pop3/commands.c,v
retrieving revision 1.53.2.4
retrieving revision 1.53.2.5
diff -u -d -r1.53.2.4 -r1.53.2.5
--- commands.c 14 Feb 2007 18:26:29 -0000 1.53.2.4
+++ commands.c 15 Feb 2007 12:12:53 -0000 1.53.2.5
@@ -452,12 +452,8 @@
client->deleted_size = 0;
}
- /* forget all our seen flag updates as well.. */
- mailbox_transaction_rollback(&client->trans);
- client->trans = mailbox_transaction_begin(client->mailbox, 0);
-
if (enable_last_command) {
- /* remove all \Seen flags */
+ /* remove all \Seen flags (as specified by RFC 1460) */
memset(&seqset, 0, sizeof(seqset));
memset(&search_arg, 0, sizeof(search_arg));
seqset.seq1 = 1;
@@ -475,6 +471,11 @@
}
mail_free(&mail);
(void)mailbox_search_deinit(&search_ctx);
+ } else {
+ /* forget all our seen flag updates.
+ FIXME: is this needed? it loses data added to cache file */
+ mailbox_transaction_rollback(&client->trans);
+ client->trans = mailbox_transaction_begin(client->mailbox, 0);
}
client_send_line(client, "+OK");
More information about the dovecot-cvs
mailing list