mailbox-list-maildir.c revision 3d6fdafca17c073606b63745ca8638e035e871f4
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen/* Copyright (c) 2006-2012 Dovecot authors, see the included COPYING file */
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainenextern struct mailbox_list maildir_mailbox_list;
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainenextern struct mailbox_list imapdir_mailbox_list;
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainenstatic struct mailbox_list *maildir_list_alloc(void)
2ef5254ab6b446b93ce7733bc96eeefa6f731ee4Timo Sirainen pool = pool_alloconly_create("maildir++ list", 2048);
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen list = p_new(pool, struct maildir_mailbox_list, 1);
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen list->global_temp_prefix = MAILDIR_GLOBAL_TEMP_PREFIX;
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen list->temp_prefix = p_strconcat(pool, list->global_temp_prefix,
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainenstatic struct mailbox_list *imapdir_list_alloc(void)
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen pool = pool_alloconly_create("imapdir list", 1024);
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen list = p_new(pool, struct maildir_mailbox_list, 1);
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen list->global_temp_prefix = IMAPDIR_GLOBAL_TEMP_PREFIX;
58c61ac5650583d21c891e61e051c614290d31fbTimo Sirainen list->temp_prefix = p_strconcat(pool, list->global_temp_prefix,
const char *name)
return dir;
return name;
if (p == NULL)
return name;
const char *root_dir;
switch (type) {
return NULL;
return NULL;
const char *path;
const char *root_dir;
int ret = 0;
if (ret < 0)
if (ret == 0) {
int ret;
return ret;
const char *path;
char old_ns_sep;
int ret;
ret = 0;
const char *name;
for (i = 0; i < count; i++) {
return ret;
int ret;
bool found;
oldname));
T_BEGIN {
} T_END;
if (ret < 0)
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,