diff options
author | Colomban Wendling <[email protected]> | 2024-09-03 16:32:35 +0200 |
---|---|---|
committer | Luke from DC <[email protected]> | 2024-09-03 23:51:29 +0000 |
commit | 7ef327f6f269c7a49357e001cd41d7aaf5807749 (patch) | |
tree | 98df9ae16ca338f365e12e0d47cc62d8383ec61a /src/unit-category.c | |
parent | fe495df3ec39c155eacecbfbfbdd3d6ad45c46ec (diff) | |
download | mate-calc-7ef327f6f269c7a49357e001cd41d7aaf5807749.tar.bz2 mate-calc-7ef327f6f269c7a49357e001cd41d7aaf5807749.tar.xz |
The ParseNode's value must be valid to pass to `free()`, as it's done
unconditionally if the expression is invalid. However, for some
functions a shortuct was taken avoiding duplicating memory. This was
OK in case the expression is valid because the evaluation function
would convert it and set the pointer back to NULL; but it's not OK if
the expression is invalid as the evaluation doesn't happen and the
pointer is not reset before being freed.
Fixes #226.
Diffstat (limited to 'src/unit-category.c')
0 files changed, 0 insertions, 0 deletions