[dovecot-cvs]
dovecot/src/imap cmd-expunge.c, 1.11, 1.12 imap-sync.c, 1.10, 1.11
cras at dovecot.org
cras at dovecot.org
Sun May 8 13:09:45 EEST 2005
Update of /var/lib/cvs/dovecot/src/imap
In directory talvi:/tmp/cvs-serv1480/imap
Modified Files:
cmd-expunge.c imap-sync.c
Log Message:
Removed SYNC_FAST_FLAG from EXPUNGE command. Changed delay-newmail
workaround to also delay EXPUNGE notifications, otherwise things break.
Changed index to force this with assert.
Index: cmd-expunge.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/imap/cmd-expunge.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- cmd-expunge.c 5 Feb 2005 18:07:26 -0000 1.11
+++ cmd-expunge.c 8 May 2005 10:09:43 -0000 1.12
@@ -28,10 +28,9 @@
if (search_arg == NULL)
return TRUE;
- if (imap_expunge(client->mailbox, search_arg)) {
- return cmd_sync(cmd, MAILBOX_SYNC_FLAG_FAST,
- "OK Expunge completed.");
- } else {
+ if (imap_expunge(client->mailbox, search_arg))
+ return cmd_sync(cmd, 0, "OK Expunge completed.");
+ else {
client_send_storage_error(cmd,
mailbox_get_storage(client->mailbox));
return TRUE;
@@ -45,10 +44,9 @@
if (!client_verify_open_mailbox(cmd))
return TRUE;
- if (imap_expunge(client->mailbox, NULL)) {
- return cmd_sync(cmd, MAILBOX_SYNC_FLAG_FAST,
- "OK Expunge completed.");
- } else {
+ if (imap_expunge(client->mailbox, NULL))
+ return cmd_sync(cmd, 0, "OK Expunge completed.");
+ else {
client_send_storage_error(cmd,
mailbox_get_storage(client->mailbox));
return TRUE;
Index: imap-sync.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/imap/imap-sync.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- imap-sync.c 15 Mar 2005 19:01:51 -0000 1.10
+++ imap-sync.c 8 May 2005 10:09:43 -0000 1.11
@@ -196,8 +196,14 @@
}
if ((client_workarounds & WORKAROUND_DELAY_NEWMAIL) != 0 &&
- (flags & MAILBOX_SYNC_FLAG_FAST) != 0)
- flags |= MAILBOX_SYNC_FLAG_NO_NEWMAIL;
+ (flags & MAILBOX_SYNC_FLAG_FAST) != 0) {
+ /* expunges might break just as badly as new mail
+ notifications. besides, currently indexing code doesn't
+ handle expunges + no-newmail so this is required, unless
+ we did this only for no-expunges case.. */
+ flags |= MAILBOX_SYNC_FLAG_NO_NEWMAIL |
+ MAILBOX_SYNC_FLAG_NO_EXPUNGES;
+ }
ctx = p_new(cmd->pool, struct cmd_sync_context, 1);
ctx->tagline = p_strdup(cmd->pool, tagline);
More information about the dovecot-cvs
mailing list