Mercurial > dovecot > original-hg > dovecot-1.2
changeset 8948:7364e19b703e HEAD
Maildir++ layout: Allow selecting namespace prefix if inbox=no.
With Maildir this allows opening the "mailbox root" (i.e. INBOX).
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Wed, 15 Apr 2009 19:47:20 -0400 |
parents | 71ee47b69bc7 |
children | 508bbbd4e6f6 |
files | src/lib-storage/list/mailbox-list-maildir.c |
diffstat | 1 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- 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;