diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1998-07-13 04:38:01 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1998-07-13 04:38:01 +0000 |
commit | 35c6e6af5ba2c405a91dc6b9e4af833d0979ed22 (patch) | |
tree | 7f54dda0bcda0a58eb5229def03ce3015c98a2b5 /eval.c | |
parent | 71d408a6c3298b229c0f1d2ff7159ca410a4c612 (diff) |
str2cstr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@266 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval.c')
-rw-r--r-- | eval.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -3958,11 +3958,11 @@ f_eval(argc, argv, self) int line = 0; rb_scan_args(argc, argv, "13", &src, &scope, &vfile, &vline); - if (!NIL_P(vfile)) { + if (argc >= 3) { Check_Type(vfile, T_STRING); file = RSTRING(vfile)->ptr; } - if (!NIL_P(vline)) { + if (argc >= 4) { line = NUM2INT(vline); } |