summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-06-24 13:32:57 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-06-24 13:32:57 +0000
commita5c2d584284e2b137b1d4d06574470a971c9087e (patch)
tree590a6b41b7e0a33e640f2f78b7683f2827c59754
parent62deb7dbbda5104c352abd723053bd1b18e50dbf (diff)
* eval_method.h (rb_add_method): fix to check 0.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12602 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog4
-rw-r--r--eval_method.h2
2 files changed, 5 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 0ab5402..653919e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Sun Jun 24 22:32:00 2007 Koichi Sasada <ko1@atdot.net>
+
+ * eval_method.h (rb_add_method): fix to check 0.
+
Sun Jun 24 22:00:17 2007 Koichi Sasada <ko1@atdot.net>
* insn_send.ci: removed.
diff --git a/eval_method.h b/eval_method.h
index ac092d7..1f4ba33 100644
--- a/eval_method.h
+++ b/eval_method.h
@@ -150,7 +150,7 @@ rb_add_method(VALUE klass, ID mid, NODE * node, int noex)
rb_warning("method redefined; discarding old %s", rb_id2name(mid));
}
}
- if (klass == rb_cObject && node->nd_mid == init) {
+ if (klass == rb_cObject && node && node->nd_mid == init) {
rb_warn("redefining Object#initialize may cause infinite loop");
}
}