dovecot-2.2: lib-storage: Non-crashing way of avoiding fs lookup...

dovecot at dovecot.org dovecot at dovecot.org
Sat Nov 23 00:38:54 EET 2013


details:   http://hg.dovecot.org/dovecot-2.2/rev/f1e8dc453fd2
changeset: 17010:f1e8dc453fd2
user:      Timo Sirainen <tss at iki.fi>
date:      Sat Nov 23 00:38:41 2013 +0200
description:
lib-storage: Non-crashing way of avoiding fs lookups for storages without mail root.

diffstat:

 src/lib-storage/mailbox-list.c |  4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diffs (23 lines):

diff -r 7df4141eb57a -r f1e8dc453fd2 src/lib-storage/mailbox-list.c
--- a/src/lib-storage/mailbox-list.c	Sat Nov 23 00:00:43 2013 +0200
+++ b/src/lib-storage/mailbox-list.c	Sat Nov 23 00:38:41 2013 +0200
@@ -843,7 +843,6 @@
 				      const char *name,
 				      struct mailbox_permissions *permissions_r)
 {
-	struct mail_storage *storage;
 	const char *path, *parent_name, *parent_path, *p;
 	struct stat st;
 
@@ -866,10 +865,9 @@
 		(void)mailbox_list_get_root_path(list, MAILBOX_LIST_PATH_TYPE_DIR,
 						 &path);
 	}
-	mailbox_list_get_default_storage(list, &storage);
 
 	if (path == NULL ||
-	    (storage->class_flags & MAIL_STORAGE_CLASS_FLAG_NO_ROOT) != 0) {
+	    (list->flags & MAILBOX_LIST_FLAG_NO_MAIL_FILES) != 0) {
 		/* no filesystem support in storage */
 	} else if (stat(path, &st) < 0) {
 		if (errno == EACCES) {


More information about the dovecot-cvs mailing list