summaryrefslogtreecommitdiff
path: root/vm_insnhelper.c
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-08-09 08:31:28 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-08-09 08:31:28 +0000
commit2132fb9fd1fb8d32e5f1ae681fafbf295b91eac5 (patch)
treef3b231a3381a88dc086a19459ae745b6a82deec4 /vm_insnhelper.c
parentf6d9f6fd2a7ad2f20472f3704ae7d4e810627c54 (diff)
merge revision(s) 57415,57474: [Backport #13239]
eval.c: copy special exception * eval.c (setup_exception): make unfrozen copy of special exception before setting up a cause. test_io.rb: separate a test * test/ruby/test_io.rb (test_closed_stream_in_rescue): run in a separated process. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_3@59538 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r--vm_insnhelper.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c
index b90621bd1f..2f786e3c84 100644
--- a/vm_insnhelper.c
+++ b/vm_insnhelper.c
@@ -25,17 +25,17 @@
static rb_control_frame_t *vm_get_ruby_level_caller_cfp(const rb_thread_t *th, const rb_control_frame_t *cfp);
VALUE
-ruby_vm_sysstack_error_copy(void)
+ruby_vm_special_exception_copy(VALUE exc)
{
- VALUE e = rb_obj_alloc(rb_eSysStackError);
- rb_obj_copy_ivar(e, sysstack_error);
+ VALUE e = rb_obj_alloc(rb_class_real(RBASIC_CLASS(exc)));
+ rb_obj_copy_ivar(e, exc);
return e;
}
static void
vm_stackoverflow(void)
{
- rb_exc_raise(ruby_vm_sysstack_error_copy());
+ rb_exc_raise(ruby_vm_special_exception_copy(sysstack_error));
}
#if VM_CHECK_MODE > 0