diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | process.c | 1 |
2 files changed, 5 insertions, 0 deletions
@@ -1,3 +1,7 @@ +Thu Oct 9 23:19:02 2008 Yusuke Endoh <mame@tsg.ne.jp> + + * process.c (rb_run_exec_options): fix resource leak. + Thu Oct 9 22:13:58 2008 Yusuke Endoh <mame@tsg.ne.jp> * test/ruby/test_module.rb (test_remove_class_variable): add a test @@ -2089,6 +2089,7 @@ rb_run_exec_options(const struct rb_exec_arg *e, struct rb_exec_arg *s) char *cwd = my_getcwd(); rb_ary_store(soptions, EXEC_OPTION_CHDIR, hide_obj(rb_str_new2(cwd))); + xfree(cwd); } if (chdir(RSTRING_PTR(obj)) == -1) return -1; |