summaryrefslogtreecommitdiff
path: root/eval.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-09-30 12:26:23 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-09-30 12:26:23 +0000
commit327b22ad77bf285206d787d0f0c648234d95b707 (patch)
treed454d2032569ade92d384080f597cf8cb4f5aaa8 /eval.c
parentc879b60152ccfb4317ae86c22f8947c3b1d442bb (diff)
eval.c: check type
* eval.c (ignored_block): check argument type, which must be Module. [ruby-dev:50270] [Bug #13956] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60077 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval.c')
-rw-r--r--eval.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/eval.c b/eval.c
index f5896f6..00b5156 100644
--- a/eval.c
+++ b/eval.c
@@ -1482,6 +1482,7 @@ static void
ignored_block(VALUE module, const char *klass)
{
const char *anon = "";
+ Check_Type(module, T_MODULE);
if (!RTEST(rb_search_class_path(module))) {
anon = ", maybe for Module.new";
}