From: Martti Rannanjärvi Date: Fri, 9 Aug 2019 11:07:58 +0000 (+0300) Subject: imap: Only send NIL on GETMETADATA when query depth is 0 X-Git-Tag: 2.3.8~155 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=30e452ea54930a093d65d7477af9192876c09d54;p=thirdparty%2Fdovecot%2Fcore.git imap: Only send NIL on GETMETADATA when query depth is 0 --- diff --git a/src/imap/cmd-getmetadata.c b/src/imap/cmd-getmetadata.c index 641057c389..3a789adee0 100644 --- a/src/imap/cmd-getmetadata.c +++ b/src/imap/cmd-getmetadata.c @@ -301,7 +301,8 @@ cmd_getmetadata_send_entry_tree(struct imap_getmetadata_context *ctx, } while (ctx->depth == 1 && strchr(subentry, '/') != NULL); entry = t_strconcat(str_c(ctx->iter_entry_prefix), subentry, NULL); } - cmd_getmetadata_send_entry(ctx, entry, ctx->iter == NULL); + /* send NIL only on depth 0 query */ + cmd_getmetadata_send_entry(ctx, entry, ctx->depth == 0); if (ctx->cur_stream != NULL) { if (!cmd_getmetadata_stream_continue(ctx))