From 3e557a979ecc2c9a43ffa3bbdb8fc2a6c5cfca61 Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 6 Mar 2015 01:31:03 +0000 Subject: vm_eval.c: next super class from the original * vm_eval.c (vm_call_super): search next super class from the original class, to get rid of infinite recursion with prepending. a patch by Seiei Higa at [ruby-core:68434]. [ruby-core:68093] [Bug #10847] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49867 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- vm_eval.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'vm_eval.c') diff --git a/vm_eval.c b/vm_eval.c index 6eeee5f02e..4039b6c9f2 100644 --- a/vm_eval.c +++ b/vm_eval.c @@ -273,7 +273,8 @@ vm_call_super(rb_thread_t *th, int argc, const VALUE *argv) rb_bug("vm_call_super: should not be reached"); } - klass = RCLASS_SUPER(cfp->klass); + klass = RCLASS_ORIGIN(cfp->klass); + klass = RCLASS_SUPER(klass); id = cfp->me->def->original_id; me = rb_method_entry(klass, id, &klass); if (!me) { -- cgit v1.2.3