dovecot-2.0: dict quota: Don't fail quota recalculation if mailb...
dovecot at dovecot.org
dovecot at dovecot.org
Fri Aug 6 18:01:24 EEST 2010
details: http://hg.dovecot.org/dovecot-2.0/rev/a933f7db45f9
changeset: 11953:a933f7db45f9
user: Timo Sirainen <tss at iki.fi>
date: Fri Aug 06 16:01:20 2010 +0100
description:
dict quota: Don't fail quota recalculation if mailbox syncing fails with non-temp error.
This could happen e.g. with mbox if a file isn't in a valid mbox.
diffstat:
src/plugins/quota/quota-count.c | 7 +------
1 files changed, 1 insertions(+), 6 deletions(-)
diffs (24 lines):
diff -r 4ef2280ee490 -r a933f7db45f9 src/plugins/quota/quota-count.c
--- a/src/plugins/quota/quota-count.c Fri Aug 06 15:11:06 2010 +0100
+++ b/src/plugins/quota/quota-count.c Fri Aug 06 16:01:20 2010 +0100
@@ -32,7 +32,7 @@
box = mailbox_alloc(ns->list, storage_name,
MAILBOX_FLAG_READONLY | MAILBOX_FLAG_KEEP_RECENT);
- if (mailbox_open(box) < 0) {
+ if (mailbox_sync(box, MAILBOX_SYNC_FLAG_FULL_READ) < 0) {
mail_storage_get_last_error(mailbox_get_storage(box), &error);
mailbox_free(&box);
if (error == MAIL_ERROR_TEMP)
@@ -41,11 +41,6 @@
return 0;
}
- if (mailbox_sync(box, MAILBOX_SYNC_FLAG_FULL_READ) < 0) {
- mailbox_free(&box);
- return -1;
- }
-
trans = mailbox_transaction_begin(box, 0);
mail = mail_alloc(trans, MAIL_FETCH_PHYSICAL_SIZE, NULL);
More information about the dovecot-cvs
mailing list