comparison src/structs.h @ 21220:ad13736a1783 v8.2.1161

patch 8.2.1161: Vim9: using freed memory Commit: https://github.com/vim/vim/commit/8e2730a315b8b06192f5fc822dc218dbb3cff7ae Author: Bram Moolenaar <Bram@vim.org> Date: Wed Jul 8 22:01:49 2020 +0200 patch 8.2.1161: Vim9: using freed memory Problem: Vim9: using freed memory. Solution: Put pointer back in evalarg instead of freeing it.
author Bram Moolenaar <Bram@vim.org>
date Wed, 08 Jul 2020 22:15:04 +0200
parents 09377fd59b2e
children 13b1567ae0c6
comparison
equal deleted inserted replaced
21219:8ad4d2754054 21220:ad13736a1783
1771 // Used to collect lines while parsing them, so that they can be 1771 // Used to collect lines while parsing them, so that they can be
1772 // concatenated later. Used when "eval_ga.ga_itemsize" is not zero. 1772 // concatenated later. Used when "eval_ga.ga_itemsize" is not zero.
1773 // "eval_ga.ga_data" is a list of pointers to lines. 1773 // "eval_ga.ga_data" is a list of pointers to lines.
1774 garray_T eval_ga; 1774 garray_T eval_ga;
1775 1775
1776 // pointer to the line obtained with getsourceline() 1776 // pointer to the last line obtained with getsourceline()
1777 char_u *eval_tofree; 1777 char_u *eval_tofree;
1778
1779 // pointer to the lines concatenated for a lambda.
1780 char_u *eval_tofree_lambda;
1778 } evalarg_T; 1781 } evalarg_T;
1779 1782
1780 // Flags for expression evaluation. 1783 // Flags for expression evaluation.
1781 #define EVAL_EVALUATE 1 // when missing don't actually evaluate 1784 #define EVAL_EVALUATE 1 // when missing don't actually evaluate
1782 #define EVAL_CONSTANT 2 // when not a constant return FAIL 1785 #define EVAL_CONSTANT 2 // when not a constant return FAIL