From 43f11a93385c4848bfad49510bdea2849f241816 Mon Sep 17 00:00:00 2001 From: Preston Pan Date: Sun, 8 Jan 2023 19:17:57 -0800 Subject: add some frees; still need to fix high amounts of memory leakage --- src/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/main.c') diff --git a/src/main.c b/src/main.c index 1d68cdb..858334b 100644 --- a/src/main.c +++ b/src/main.c @@ -167,7 +167,8 @@ int main(int argc, char **argv) { ast_t *root = eval(visitor); /* print_root(root); */ ast_free(root); - free(visitor); + ast_free(visitor->root); + visitor_free(visitor); hash_table_free(parser->symbol_table); parser_free(parser); free(lexer); -- cgit