aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2022-06-25 18:05:52 +0200
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2022-06-27 12:13:20 +0200
commitd42df42ec5a5f0ac7e58bfbfa6ceadd706b5517f (patch)
tree18ffe4b93eec905205041d724b8ab40c96f0a3d9
parent1777fe6b3ce8359b49d133924f1488ce0b0cc628 (diff)
downloadsparse-d42df42ec5a5f0ac7e58bfbfa6ceadd706b5517f.tar.gz
inline: free symbol list after use
We usually don't free allocated memory because it's not known when the allocated objects aren't used anymore. But here it's pretty obvious, so free this symbol list. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
-rw-r--r--inline.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/inline.c b/inline.c
index 68f235c2..a7ab73d3 100644
--- a/inline.c
+++ b/inline.c
@@ -567,6 +567,7 @@ int inline_function(struct expression *expr, struct symbol *sym)
stmt->inline_fn = sym;
unset_replace_list(fn_symbol_list);
+ free_ptr_list(&fn_symbol_list);
return 1;
}