# HG changeset patch # User Timo Sirainen # Date 1239839240 14400 # Node ID 8ea3e0549b5abd733fbc5e8dc735c031236b407d # Parent def8b99b1a02b5c2939144015b64131e66f3c8b1 Maildir++ layout: Allow selecting namespace prefix if inbox=no. With Maildir this allows opening the "mailbox root" (i.e. INBOX). diff -r def8b99b1a02 -r 8ea3e0549b5a src/lib-storage/list/mailbox-list-maildir.c --- a/src/lib-storage/list/mailbox-list-maildir.c Wed Apr 15 18:06:21 2009 -0400 +++ b/src/lib-storage/list/mailbox-list-maildir.c Wed Apr 15 19:47:20 2009 -0400 @@ -134,6 +134,13 @@ { size_t len; + if (*name == '\0' && *list->ns->prefix != '\0' && + (list->ns->flags & NAMESPACE_FLAG_INBOX) == 0) { + /* an ugly way to get to Maildir/ root when it's not the + INBOX. */ + return TRUE; + } + if (!maildir_list_is_valid_common(list, name, &len)) return FALSE;