dovecot-2.1: fs layout: Mailbox listing returned duplicates when...
dovecot at dovecot.org
dovecot at dovecot.org
Tue Feb 28 04:29:24 EET 2012
details: http://hg.dovecot.org/dovecot-2.1/rev/07fc8baa0c9b
changeset: 14205:07fc8baa0c9b
user: Timo Sirainen <tss at iki.fi>
date: Tue Feb 28 04:29:12 2012 +0200
description:
fs layout: Mailbox listing returned duplicates when patterns contained a parent and its children.
diffstat:
src/lib-storage/list/mailbox-list-fs-iter.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diffs (13 lines):
diff -r 3b328ffffdd4 -r 07fc8baa0c9b src/lib-storage/list/mailbox-list-fs-iter.c
--- a/src/lib-storage/list/mailbox-list-fs-iter.c Mon Feb 27 16:53:50 2012 +0200
+++ b/src/lib-storage/list/mailbox-list-fs-iter.c Tue Feb 28 04:29:12 2012 +0200
@@ -360,7 +360,8 @@
childp = array_idx(&ctx->roots, i);
parentlen = strlen(*parentp);
if (strncmp(*parentp, *childp, parentlen) == 0 &&
- ((*childp)[parentlen] == ctx->sep ||
+ (parentlen == 0 ||
+ (*childp)[parentlen] == ctx->sep ||
(*childp)[parentlen] == '\0'))
array_delete(&ctx->roots, i, 1);
}
More information about the dovecot-cvs
mailing list