зеркало из https://github.com/github/ruby.git
* eval.c (rb_add_method): node may be NULL.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3077 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
e2d384d628
Коммит
f047de71e6
|
@ -1,3 +1,7 @@
|
||||||
|
Fri Nov 22 18:31:46 2002 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
|
* eval.c (rb_add_method): node may be NULL.
|
||||||
|
|
||||||
Thu Nov 21 20:53:06 2002 Minero Aoki <aamine@loveruby.net>
|
Thu Nov 21 20:53:06 2002 Minero Aoki <aamine@loveruby.net>
|
||||||
|
|
||||||
* lib/net/smtp.rb: changes coding style.
|
* lib/net/smtp.rb: changes coding style.
|
||||||
|
|
2
eval.c
2
eval.c
|
@ -247,7 +247,7 @@ rb_add_method(klass, mid, node, noex)
|
||||||
if (ruby_safe_level >= 4 && (klass == rb_cObject || !OBJ_TAINTED(klass))) {
|
if (ruby_safe_level >= 4 && (klass == rb_cObject || !OBJ_TAINTED(klass))) {
|
||||||
rb_raise(rb_eSecurityError, "Insecure: can't define method");
|
rb_raise(rb_eSecurityError, "Insecure: can't define method");
|
||||||
}
|
}
|
||||||
if (mid == init && !FL_TEST(klass, FL_SINGLETON) && nd_type(node) != NODE_ZSUPER) {
|
if (mid == init && !FL_TEST(klass, FL_SINGLETON) && node && nd_type(node) != NODE_ZSUPER) {
|
||||||
noex = NOEX_PRIVATE | (noex & NOEX_NOSUPER);
|
noex = NOEX_PRIVATE | (noex & NOEX_NOSUPER);
|
||||||
}
|
}
|
||||||
if (OBJ_FROZEN(klass)) rb_error_frozen("class/module");
|
if (OBJ_FROZEN(klass)) rb_error_frozen("class/module");
|
||||||
|
|
Загрузка…
Ссылка в новой задаче