[dovecot-cvs] dovecot/src/pop3 commands.c,1.57,1.58
tss at dovecot.org
tss at dovecot.org
Thu Feb 15 12:12:57 UTC 2007
Update of /var/lib/cvs/dovecot/src/pop3
In directory talvi:/tmp/cvs-serv21602
Modified Files:
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.57
retrieving revision 1.58
diff -u -d -r1.57 -r1.58
--- commands.c 14 Feb 2007 18:26:32 -0000 1.57
+++ commands.c 15 Feb 2007 12:12:55 -0000 1.58
@@ -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