From: Timo Sirainen Date: Thu, 23 Oct 2025 20:18:17 +0000 (+0300) Subject: imap: Fix memory leak when using STORE with keywords on an EXAMINEd mailbox X-Git-Tag: 2.4.2~17 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=03b17b767aaea357fda996a9f769d2d1ee30aadf;p=thirdparty%2Fdovecot%2Fcore.git imap: Fix memory leak when using STORE with keywords on an EXAMINEd mailbox --- diff --git a/src/imap/cmd-store.c b/src/imap/cmd-store.c index ab24612082..8edf080d05 100644 --- a/src/imap/cmd-store.c +++ b/src/imap/cmd-store.c @@ -160,6 +160,8 @@ bool cmd_store(struct client_command_context *cmd) if (client->mailbox_examined) { mail_search_args_unref(&search_args); + if (ctx.keywords != NULL) + mailbox_keywords_unref(&ctx.keywords); if (ctx.max_modseq < (uint64_t)-1) reply = "NO CONDSTORE failed: Mailbox is read-only."; else