From ad9568060eefbf79073f260249fe1ff8df59bf53 Mon Sep 17 00:00:00 2001 From: mingodad Date: Tue, 25 Mar 2014 18:06:14 +0000 Subject: A possible fix for the memory leak reported by valgrind when running tcctest.c with tcc. --- libtcc.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libtcc.c') diff --git a/libtcc.c b/libtcc.c index dc78643..601999e 100644 --- a/libtcc.c +++ b/libtcc.c @@ -1094,6 +1094,8 @@ LIBTCCAPI void tcc_delete(TCCState *s1) # endif #endif + if(s1->sym_attrs) tcc_free(s1->sym_attrs); + tcc_free(s1); } -- cgit v1.3.1