mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* vm_insnhelper.c (caller_setup_args): should ensure if the value
from to_proc is a real Proc. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18575 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
5068e137d0
commit
e0889dbf38
2 changed files with 6 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
|||
Wed Aug 13 17:31:12 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* vm_insnhelper.c (caller_setup_args): should ensure if the value
|
||||
from to_proc is a real Proc.
|
||||
|
||||
Wed Aug 13 17:28:29 2008 Akinori MUSHA <knu@iDaemons.org>
|
||||
|
||||
* common.mk: regint.h no longer includes vm_core.h.
|
||||
|
|
|
@ -221,7 +221,7 @@ caller_setup_args(const rb_thread_t *th, rb_control_frame_t *cfp, VALUE flag,
|
|||
if (proc != Qnil) {
|
||||
if (!rb_obj_is_proc(proc)) {
|
||||
VALUE b = rb_check_convert_type(proc, T_DATA, "Proc", "to_proc");
|
||||
if (NIL_P(b)) {
|
||||
if (NIL_P(b) || !rb_obj_is_proc(b)) {
|
||||
rb_raise(rb_eTypeError,
|
||||
"wrong argument type %s (expected Proc)",
|
||||
rb_obj_classname(proc));
|
||||
|
|
Loading…
Add table
Reference in a new issue