diff options
author | normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-10-12 21:53:01 +0000 |
---|---|---|
committer | normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-10-12 21:53:01 +0000 |
commit | eb5147779da081b5d141a1ab3a6d8a582fdeed28 (patch) | |
tree | 2ff7bd421f0f5894cda8c80630ef8660755f82f6 /array.c | |
parent | 6769d5d5accf274e211d60f01bfd8b1dd08f9ef4 (diff) | |
download | ruby-eb5147779da081b5d141a1ab3a6d8a582fdeed28.tar.gz |
array.c: swap volatile for RB_GC_GUARD
* array.c (ary_recycle_hash): add RB_GC_GUARD
(rb_ary_diff): remove volatile
[Bug #10369]
The RB_GC_GUARD seems needed for most of the ary_recycle_hash
functions anyways.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'array.c')
-rw-r--r-- | array.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -3986,6 +3986,7 @@ ary_recycle_hash(VALUE hash) RHASH(hash)->ntbl = 0; st_free_table(tbl); } + RB_GC_GUARD(hash); } /* @@ -4009,7 +4010,7 @@ static VALUE rb_ary_diff(VALUE ary1, VALUE ary2) { VALUE ary3; - volatile VALUE hash; + VALUE hash; long i; hash = ary_make_hash(to_ary(ary2)); |