# HG changeset patch # User Bram Moolenaar # Date 1641656703 -3600 # Node ID 5d851ce07caf5cd666fd664a066110d3d556b1e4 # Parent 77aed3cffbd3cf4446665bf79d9cde4bf675dbd1 patch 8.2.4041: using unitialized pointer Commit: https://github.com/vim/vim/commit/aa9b3cacd52a6c34591bbd89fb6b06d4c097fe03 Author: Bram Moolenaar Date: Sat Jan 8 15:44:22 2022 +0000 patch 8.2.4041: using unitialized pointer Problem: Using unitialized pointer. Solution: Store "ht" when variable is in another script. diff --git a/src/evalvars.c b/src/evalvars.c --- a/src/evalvars.c +++ b/src/evalvars.c @@ -2898,7 +2898,11 @@ find_var_also_in_script(char_u *name, ha 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 --- 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 */ /**/ + 4041, +/**/ 4040, /**/ 4039,