dovecot-2.1: mailbox list indexes: Disable index files for share...

dovecot at dovecot.org dovecot at dovecot.org
Sun Oct 2 16:51:53 EEST 2011


details:   http://hg.dovecot.org/dovecot-2.1/rev/37c4e282a605
changeset: 13585:37c4e282a605
user:      Timo Sirainen <tss at iki.fi>
date:      Sun Oct 02 16:59:51 2011 +0300
description:
mailbox list indexes: Disable index files for shared/public namespaces.

diffstat:

 src/lib-storage/list/index-mailbox-list.c |  9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diffs (20 lines):

diff -r e06e178c8fd1 -r 37c4e282a605 src/lib-storage/list/index-mailbox-list.c
--- a/src/lib-storage/list/index-mailbox-list.c	Sun Oct 02 16:55:45 2011 +0300
+++ b/src/lib-storage/list/index-mailbox-list.c	Sun Oct 02 16:59:51 2011 +0300
@@ -807,8 +807,15 @@
 		MODULE_CONTEXT_SET(list, index_mailbox_list_module, ilist);
 		return;
 	}
-	if (*dir == '\0')
+	if (*dir == '\0') {
+		/* in-memory indexes */
 		dir = NULL;
+	} else if (list->ns->type != NAMESPACE_PRIVATE) {
+		/* don't create index files for shared/public mailboxes.
+		   their indexes may be shared between multiple users,
+		   each of which may have different ACLs */
+		dir = NULL;
+	}
 
 	ilist = p_new(list->pool, struct index_mailbox_list, 1);
 	ilist->module_ctx.super = list->v;


More information about the dovecot-cvs mailing list