summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-11-16 17:02:37 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-11-16 17:02:37 +0000
commited86cd0536fd1e77a17d69bf30fe5ef531e182ca (patch)
tree4e560ce9cc5ce8997891ff052607b6449572cabd
parentb29b2962d2b58587fb1a70a3e97b109757e7586e (diff)
vm.c: gc guard
* vm.c (vm_collect_usage_operand): prevent from GC. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37690 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--vm.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/vm.c b/vm.c
index 5e7b61df35..f1dd008cd4 100644
--- a/vm.c
+++ b/vm.c
@@ -2515,6 +2515,7 @@ vm_collect_usage_operand(int insn, int n, VALUE op)
valstr = insn_operand_intern(GET_THREAD()->cfp->iseq, insn, n, op, 0, 0, 0, 0);
RUBY_DTRACE_INSN_OPERAND(RSTRING_PTR(valstr), rb_insns_name(insn));
+ RB_GC_GUARD(valstr);
}
if (ruby_vm_collect_usage_func_operand)
(*ruby_vm_collect_usage_func_operand)(insn, n, op);