ruby-changes:34388
From: ko1 <ko1@a...>
Date: Fri, 20 Jun 2014 05:28:04 +0900 (JST)
Subject: [ruby-changes:34388] ko1:r46469 (trunk): * vm_eval.c (rb_catch_protect): fix same problem of [Bug #9961].
ko1 2014-06-20 05:27:59 +0900 (Fri, 20 Jun 2014) New Revision: 46469 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=46469 Log: * vm_eval.c (rb_catch_protect): fix same problem of [Bug #9961]. * vm_eval.c (rb_iterate): ditto. Modified files: trunk/ChangeLog trunk/vm_eval.c Index: ChangeLog =================================================================== --- ChangeLog (revision 46468) +++ ChangeLog (revision 46469) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Fri Jun 20 05:26:27 2014 Koichi Sasada <ko1@a...> + + * vm_eval.c (rb_catch_protect): fix same problem of [Bug #9961]. + + * vm_eval.c (rb_iterate): ditto. + Thu Jun 19 21:41:30 2014 Koichi Sasada <ko1@a...> * vm.c (rb_vm_rewind_cfp): add new function to rewind specified cfp Index: vm_eval.c =================================================================== --- vm_eval.c (revision 46468) +++ vm_eval.c (revision 46469) @@ -1104,10 +1104,11 @@ rb_iterate(VALUE (* it_proc) (VALUE), VA https://github.com/ruby/ruby/blob/trunk/vm_eval.c#L1104 VALUE *cep = cfp->ep; if (cep == escape_ep) { + rb_vm_rewind_cfp(th, cfp); + state = 0; th->state = 0; th->errinfo = Qnil; - th->cfp = cfp; goto iter_retry; } } @@ -1863,7 +1864,7 @@ rb_catch_protect(VALUE t, rb_block_call_ https://github.com/ruby/ruby/blob/trunk/vm_eval.c#L1864 val = (*func)(tag, data, 1, (const VALUE *)&tag, Qnil); } else if (state == TAG_THROW && RNODE(th->errinfo)->u1.value == tag) { - th->cfp = saved_cfp; + rb_vm_rewind_cfp(th, saved_cfp); val = th->tag->retval; th->errinfo = Qnil; state = 0; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/