From: Timo Sirainen Date: Wed, 18 Nov 2009 00:25:28 +0000 (-0500) Subject: dsync: Try creating INBOX before fallbacking to just updating it. X-Git-Tag: 2.0.beta1~130 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a3efa71d522fafe9832119af5da9e4df1d6d988d;p=thirdparty%2Fdovecot%2Fcore.git dsync: Try creating INBOX before fallbacking to just updating it. --HG-- branch : HEAD --- diff --git a/src/dsync/dsync-worker-local.c b/src/dsync/dsync-worker-local.c index 55effc19eb..edcddc0b96 100644 --- a/src/dsync/dsync-worker-local.c +++ b/src/dsync/dsync-worker-local.c @@ -890,12 +890,9 @@ local_worker_create_mailbox(struct dsync_worker *_worker, } local_worker_copy_mailbox_update(dsync_box, &update); - if (strcasecmp(dsync_box->name, "INBOX") == 0) + ret = mailbox_create(box, &update, dsync_box->uid_validity == 0); + if (ret < 0 && strcasecmp(dsync_box->name, "INBOX") == 0) ret = mailbox_update(box, &update); - else { - ret = mailbox_create(box, &update, - dsync_box->uid_validity == 0); - } if (ret < 0) { dsync_worker_set_failure(_worker); i_error("Can't create mailbox %s: %s", dsync_box->name,