Skip to content

Commit

Permalink
quota: Fixed namespace filtering for dict and count backends.
Browse files Browse the repository at this point in the history
  • Loading branch information
sirainen committed Jan 18, 2016
1 parent 47a53a8 commit c80cf58
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/plugins/quota/quota-count.c
Expand Up @@ -100,10 +100,12 @@ quota_mailbox_iter_next(struct quota_mailbox_iter *iter)

if (iter->iter == NULL) {
namespaces = array_get(&iter->root->quota->namespaces, &count);
if (iter->ns_idx >= count)
return NULL;
do {
if (iter->ns_idx >= count)
return NULL;

iter->ns = namespaces[iter->ns_idx++];
iter->ns = namespaces[iter->ns_idx++];
} while (!quota_root_is_namespace_visible(iter->root, iter->ns));
iter->iter = mailbox_list_iter_init(iter->ns->list, "*",
MAILBOX_LIST_ITER_SKIP_ALIASES |
MAILBOX_LIST_ITER_RETURN_NO_FLAGS |
Expand Down

0 comments on commit c80cf58

Please sign in to comment.