From: Timo Sirainen Date: Sun, 25 May 2008 19:31:10 +0000 (+0300) Subject: Don't crash if subscribed mailbox begins with hierarchy separator. X-Git-Tag: 1.1.rc6~22 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2651d48d2439f9734af0caa9fea5040e9ce115bc;p=thirdparty%2Fdovecot%2Fcore.git Don't crash if subscribed mailbox begins with hierarchy separator. --HG-- branch : HEAD --- diff --git a/src/lib-storage/mailbox-tree.c b/src/lib-storage/mailbox-tree.c index 79a01b9056..a43382d5e1 100644 --- a/src/lib-storage/mailbox-tree.c +++ b/src/lib-storage/mailbox-tree.c @@ -200,7 +200,7 @@ mailbox_tree_iterate_next(struct mailbox_tree_iterate_context *ctx, str_truncate(ctx->path_str, ctx->parent_pos); if (ctx->first_child) { ctx->first_child = FALSE; - if (ctx->parent_pos != 0) { + if (node->parent != NULL) { str_append_c(ctx->path_str, ctx->separator); ctx->parent_pos++; }