dovecot-1.1: If mailbox hasn't been opened when closing it, don'...
dovecot at dovecot.org
dovecot at dovecot.org
Thu Apr 24 17:03:14 EEST 2008
details: http://hg.dovecot.org/dovecot-1.1/rev/43674a726a92
changeset: 7458:43674a726a92
user: Timo Sirainen <tss at iki.fi>
date: Thu Apr 24 17:03:10 2008 +0300
description:
If mailbox hasn't been opened when closing it, don't crash when trying to
flush dirty flags.
diffstat:
1 file changed, 4 insertions(+), 1 deletion(-)
src/lib-storage/index/dbox/dbox-storage.c | 5 ++++-
diffs (15 lines):
diff -r 940641318f12 -r 43674a726a92 src/lib-storage/index/dbox/dbox-storage.c
--- a/src/lib-storage/index/dbox/dbox-storage.c Thu Apr 24 16:59:19 2008 +0300
+++ b/src/lib-storage/index/dbox/dbox-storage.c Thu Apr 24 17:03:10 2008 +0300
@@ -308,7 +308,10 @@ static int dbox_storage_mailbox_close(st
struct dbox_mailbox *mbox = (struct dbox_mailbox *)box;
int ret;
- ret = dbox_sync(mbox, TRUE);
+ if (box->opened) {
+ /* see if we want to flush dirty flags */
+ ret = dbox_sync(mbox, TRUE);
+ }
dbox_index_deinit(&mbox->dbox_index);
dbox_files_free(mbox);
More information about the dovecot-cvs
mailing list