From aa9b3cacd52a6c34591bbd89fb6b06d4c097fe03 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sat, 8 Jan 2022 15:44:22 +0000 Subject: [PATCH] patch 8.2.4041: using unitialized pointer Problem: Using unitialized pointer. Solution: Store "ht" when variable is in another script. --- src/evalvars.c | 4 ++++ src/version.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/src/evalvars.c b/src/evalvars.c index 965b2048e..3be9993fd 100644 --- a/src/evalvars.c +++ b/src/evalvars.c @@ -2898,7 +2898,11 @@ find_var_also_in_script(char_u *name, hashtab_T **htp, int no_autoload) dictitem_T *di = find_var_in_ht(ht, 0, p + 1, no_autoload); if (di != NULL) + { + if (htp != NULL) + *htp = ht; return di; + } } } } diff --git a/src/version.c b/src/version.c index 9e4ae19cb..27512d44f 100644 --- a/src/version.c +++ b/src/version.c @@ -750,6 +750,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 4041, /**/ 4040, /**/ -- 2.40.0