0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.2.1161: Vim9: using freed memory

Problem:    Vim9: using freed memory.
Solution:   Put pointer back in evalarg instead of freeing it.
This commit is contained in:
Bram Moolenaar
2020-07-08 22:01:49 +02:00
parent 6110e79a58
commit 8e2730a315
6 changed files with 67 additions and 33 deletions

View File

@@ -1773,8 +1773,11 @@ typedef struct {
// "eval_ga.ga_data" is a list of pointers to lines.
garray_T eval_ga;
// pointer to the line obtained with getsourceline()
// pointer to the last line obtained with getsourceline()
char_u *eval_tofree;
// pointer to the lines concatenated for a lambda.
char_u *eval_tofree_lambda;
} evalarg_T;
// Flags for expression evaluation.