dovecot-2.0: dsync: Another try at not increasing mailbox uidnex...

dovecot at dovecot.org dovecot at dovecot.org
Thu Jul 1 20:02:10 EEST 2010


details:   http://hg.dovecot.org/dovecot-2.0/rev/49b226835cd2
changeset: 11680:49b226835cd2
user:      Timo Sirainen <tss at iki.fi>
date:      Thu Jul 01 18:01:37 2010 +0100
description:
dsync: Another try at not increasing mailbox uidnext/highestmodseq on failure

diffstat:

 src/dsync/dsync-brain.c |  8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diffs (25 lines):

diff -r f4b809b83a13 -r 49b226835cd2 src/dsync/dsync-brain.c
--- a/src/dsync/dsync-brain.c	Thu Jul 01 17:19:41 2010 +0100
+++ b/src/dsync/dsync-brain.c	Thu Jul 01 18:01:37 2010 +0100
@@ -63,6 +63,10 @@
 	if (brain->dest_subs_list != NULL)
 		dsync_brain_subs_list_deinit(&brain->dest_subs_list);
 
+	if (dsync_worker_has_failed(brain->src_worker) ||
+	    dsync_worker_has_failed(brain->dest_worker))
+		ret = -1;
+
 	*_brain = NULL;
 	i_free(brain->mailbox);
 	i_free(brain);
@@ -693,7 +697,9 @@
 dsync_brain_sync_update_mailboxes(struct dsync_brain *brain)
 {
 	const struct dsync_brain_mailbox *mailbox;
-	bool failed_changes = dsync_brain_has_unexpected_changes(brain);
+	bool failed_changes = dsync_brain_has_unexpected_changes(brain) ||
+		dsync_worker_has_failed(brain->src_worker) ||
+		dsync_worker_has_failed(brain->dest_worker);
 
 	array_foreach(&brain->mailbox_sync->mailboxes, mailbox) {
 		/* don't update mailboxes if any changes had failed.


More information about the dovecot-cvs mailing list