1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* object.c (rb_mod_const_get): make sure the constant name is

converted to a string before searching. [ruby-core:48405]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37340 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
tenderlove 2012-10-27 01:51:58 +00:00
parent d090f17f21
commit 909bc583a4
2 changed files with 9 additions and 1 deletions

View file

@ -1,3 +1,8 @@
Sat Oct 27 10:50:53 2012 Aaron Patterson <aaron@tenderlovemaking.com>
* object.c (rb_mod_const_get): make sure the constant name is
converted to a string before searching. [ruby-core:48405]
Sat Oct 27 10:12:13 2012 URABE Shyouhei <shyouhei@ruby-lang.org>
* iseq.c (rb_iseq_compile_with_option): Instead of testing

View file

@ -1905,9 +1905,12 @@ rb_mod_const_get(int argc, VALUE *argv, VALUE mod)
}
if (SYMBOL_P(name)) {
name = rb_sym_to_s(name);
name = rb_sym_to_s(name);
}
name = rb_check_string_type(name);
Check_Type(name, T_STRING);
enc = rb_enc_get(name);
path = RSTRING_PTR(name);