From: Yasuhiro Matsumoto Date: Sat, 18 Jul 2026 14:22:31 +0000 (+0000) Subject: patch 9.2.0797: Memory leak in get_qfline_items() on alloc failure X-Git-Tag: v9.2.0797^0 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=67304a7e10a007b84654129fb4640f03c4d9ac7d;p=thirdparty%2Fvim.git patch 9.2.0797: Memory leak in get_qfline_items() on alloc failure Problem: Memory leak in get_qfline_items() on alloc failure Solution: Call dict_unref() with the dict (Yasuhiro Matsumoto). related: #20668 related: #20745 Signed-off-by: Yasuhiro Matsumoto Signed-off-by: Christian Brabandt --- diff --git a/src/quickfix.c b/src/quickfix.c index 0c7a9c9a52..039d37dffa 100644 --- a/src/quickfix.c +++ b/src/quickfix.c @@ -7222,7 +7222,10 @@ get_qfline_items(qfline_T *qfp, list_T *list) if ((dict = dict_alloc()) == NULL) return FAIL; if (list_append_dict(list, dict) == FAIL) + { + dict_unref(dict); return FAIL; + } buf[0] = qfp->qf_type; buf[1] = NUL; diff --git a/src/version.c b/src/version.c index 9a22bfa519..a234bad44f 100644 --- a/src/version.c +++ b/src/version.c @@ -759,6 +759,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 797, /**/ 796, /**/