From: Timo Sirainen Date: Tue, 24 Mar 2009 21:10:29 +0000 (-0400) Subject: dbox: No longer allow an empty MAILBOXDIR. Future code relies on this. X-Git-Tag: 1.2.beta4~11 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c0e1fa06cd97215d94757174919ea2dc7ef9b2bc;p=thirdparty%2Fdovecot%2Fcore.git dbox: No longer allow an empty MAILBOXDIR. Future code relies on this. --HG-- branch : HEAD --- diff --git a/src/lib-storage/index/dbox/dbox-storage.c b/src/lib-storage/index/dbox/dbox-storage.c index 2711f42384..74f9bdacb4 100644 --- a/src/lib-storage/index/dbox/dbox-storage.c +++ b/src/lib-storage/index/dbox/dbox-storage.c @@ -74,6 +74,11 @@ dbox_get_list_settings(struct mailbox_list_settings *list_set, layout_r, alt_dir_r, error_r) < 0) return -1; + if (*list_set->mailbox_dir_name == '\0') { + *error_r = "dbox: MAILBOXDIR must not be empty"; + return -1; + } + if (*list_set->mailbox_dir_name == '\0' && list_set->subscription_fname == subs_fname) list_set->subscription_fname = DBOX_OLD_SUBSCRIPTION_FILE_NAME;