From d1cd10421f8bfeee791ea7ecd1674eccd00000ae Mon Sep 17 00:00:00 2001 From: Mitchell Blank Jr Date: Tue, 22 May 2012 01:03:54 -0700 Subject: change example code to do mrb_close() I was hoping this would cause valgrind to complain less, but there is still a lot of memory leaked (does mrb_close() actually free all of the managed blocks?) Anyway this helps somewhat and is good practice --- src/codegen.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/codegen.c') diff --git a/src/codegen.c b/src/codegen.c index 263490f27..087dd3165 100644 --- a/src/codegen.c +++ b/src/codegen.c @@ -2291,6 +2291,7 @@ p(fib(30), \"\\n\")\n\ codedump_all(mrb, n); #endif mrb_run(mrb, mrb_proc_new(mrb, mrb->irep[0]), mrb_nil_value()); + mrb_close(mrb); return 0; } -- cgit v1.2.3