dovecot-2.0: lib-storage: Added MAIL_STORAGE_FLAG_NO_AUTOVERIFY ...

dovecot at dovecot.org dovecot at dovecot.org
Fri Oct 15 16:57:40 EEST 2010


details:   http://hg.dovecot.org/dovecot-2.0/rev/0cc916fc09f9
changeset: 12271:0cc916fc09f9
user:      Timo Sirainen <tss at iki.fi>
date:      Fri Oct 15 14:56:05 2010 +0100
description:
lib-storage: Added MAIL_STORAGE_FLAG_NO_AUTOVERIFY to skip checking storage root dir existence.

diffstat:

 src/lib-storage/mail-storage.c |  3 +++
 src/lib-storage/mail-storage.h |  5 ++++-
 2 files changed, 7 insertions(+), 1 deletions(-)

diffs (28 lines):

diff -r a8b9d7fdc646 -r 0cc916fc09f9 src/lib-storage/mail-storage.c
--- a/src/lib-storage/mail-storage.c	Fri Oct 15 14:48:31 2010 +0100
+++ b/src/lib-storage/mail-storage.c	Fri Oct 15 14:56:05 2010 +0100
@@ -190,6 +190,9 @@
 	mode_t mode;
 	gid_t gid;
 
+	if ((flags & MAIL_STORAGE_FLAG_NO_AUTOVERIFY) != 0)
+		return 0;
+
 	root_dir = mailbox_list_get_path(list, NULL,
 					 MAILBOX_LIST_PATH_TYPE_MAILBOX);
 	if (root_dir == NULL) {
diff -r a8b9d7fdc646 -r 0cc916fc09f9 src/lib-storage/mail-storage.h
--- a/src/lib-storage/mail-storage.h	Fri Oct 15 14:48:31 2010 +0100
+++ b/src/lib-storage/mail-storage.h	Fri Oct 15 14:56:05 2010 +0100
@@ -20,7 +20,10 @@
 	MAIL_STORAGE_FLAG_NO_AUTODETECTION	= 0x02,
 	/* Don't autocreate any directories. If they don't exist,
 	   fail to create the storage. */
-	MAIL_STORAGE_FLAG_NO_AUTOCREATE		= 0x04
+	MAIL_STORAGE_FLAG_NO_AUTOCREATE		= 0x04,
+	/* Don't verify existence or accessibility of any directories.
+	   Create the storage in any case. */
+	MAIL_STORAGE_FLAG_NO_AUTOVERIFY		= 0x08
 };
 
 enum mailbox_flags {


More information about the dovecot-cvs mailing list