diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | parse.y | 4 |
2 files changed, 7 insertions, 3 deletions
@@ -1,3 +1,9 @@ +Fri Jan 11 11:59:32 2013 NARUSE, Yui <naruse@ruby-lang.org> + + * string.c (dispose_string): use rb_str_free for freeing string in + parse.y. by Sokolov Yura <funny.falcon@gmail.com> + https://github.com/ruby/ruby/pull/87 fix GH-87 + Fri Jan 11 09:56:22 2013 Shugo Maeda <shugo@ruby-lang.org> * insns.def (defineclass): private constants should not be accessed @@ -5948,9 +5948,7 @@ parser_regx_options(struct parser_params *parser) static void dispose_string(VALUE str) { - /* TODO: should use another API? */ - if (RBASIC(str)->flags & RSTRING_NOEMBED) - xfree(RSTRING_PTR(str)); + rb_str_free(str); rb_gc_force_recycle(str); } |