# HG changeset patch # User Bram Moolenaar # Date 1620247504 -7200 # Node ID ae2eb2c496ed6c2c3f12645e3b2203eed554b495 # Parent 760d7c2f6bf2f8a49414d5c79bfc18a96ab72a68 patch 8.2.2835: Vim9: leaking memory in :cexpr Commit: https://github.com/vim/vim/commit/dc3e2e65c9dddcace4b24f0f364883d7ce448efb Author: Bram Moolenaar Date: Wed May 5 22:40:56 2021 +0200 patch 8.2.2835: Vim9: leaking memory in :cexpr Problem: Vim9: leaking memory in :cexpr. Solution: Also free the command line copy. diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -751,6 +751,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 2835, +/**/ 2834, /**/ 2833, diff --git a/src/vim9compile.c b/src/vim9compile.c --- a/src/vim9compile.c +++ b/src/vim9compile.c @@ -9641,6 +9641,7 @@ delete_instr(isn_T *isn) break; case ISN_CEXPR_CORE: + vim_free(isn->isn_arg.cexpr.cexpr_ref->cer_cmdline); vim_free(isn->isn_arg.cexpr.cexpr_ref); break;