dovecot-2.1: mbox: Deleting a mailbox didn't delete its index fi...

dovecot at dovecot.org dovecot at dovecot.org
Wed Apr 11 14:44:52 EEST 2012


details:   http://hg.dovecot.org/dovecot-2.1/rev/c67ea0d68b77
changeset: 14412:c67ea0d68b77
user:      Timo Sirainen <tss at iki.fi>
date:      Wed Apr 11 14:44:45 2012 +0300
description:
mbox: Deleting a mailbox didn't delete its index files.

diffstat:

 src/lib-storage/index/index-storage.c |  11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diffs (21 lines):

diff -r b016e771d8ab -r c67ea0d68b77 src/lib-storage/index/index-storage.c
--- a/src/lib-storage/index/index-storage.c	Wed Apr 11 14:29:37 2012 +0300
+++ b/src/lib-storage/index/index-storage.c	Wed Apr 11 14:44:45 2012 +0300
@@ -519,10 +519,13 @@
 		return index_storage_mailbox_delete_dir(box, FALSE);
 	}
 
-	/* specifically support symlinked shared mailboxes. a deletion will
-	   simply remove the symlink, not actually expunge any mails */
-	if (mailbox_list_delete_symlink(box->list, box->name) == 0)
-		return 0;
+	if ((box->list->flags & MAILBOX_LIST_FLAG_MAILBOX_FILES) == 0) {
+		/* specifically support symlinked shared mailboxes. a deletion
+		   will simply remove the symlink, not actually expunge any
+		   mails */
+		if (mailbox_list_delete_symlink(box->list, box->name) == 0)
+			return 0;
+	}
 
 	/* we can't easily atomically delete all mails and the mailbox. so:
 	   1) expunge all mails


More information about the dovecot-cvs mailing list