From 03b17b767aaea357fda996a9f769d2d1ee30aadf Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Thu, 23 Oct 2025 23:18:17 +0300 Subject: [PATCH] imap: Fix memory leak when using STORE with keywords on an EXAMINEd mailbox --- src/imap/cmd-store.c | 2 ++ 1 file changed, 2 insertions(+) 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 -- 2.47.3