summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-02-23 05:36:39 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-02-23 05:36:39 +0000
commitabf6499961c0cf0dd7a20323e915f9c82fcf8b4f (patch)
tree71222aae8d6db13f30e06558a63180b419791bc2 /io.c
parent7aee4189a11d747fe80275f5bd931b2d0a897771 (diff)
*** empty log message ***
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@89 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/io.c b/io.c
index 6e4c7e7d76..d5b10ee141 100644
--- a/io.c
+++ b/io.c
@@ -1955,6 +1955,8 @@ f_syscall(argc, argv)
*/
rb_secure(2);
+ if (argc == 0)
+ ArgError("too few arguments for syscall");
arg[0] = NUM2INT(argv[0]); argv++;
while (items--) {
if (FIXNUM_P(*argv)) {
@@ -1968,8 +1970,6 @@ f_syscall(argc, argv)
i++;
}
switch (argc) {
- case 0:
- ArgError("Too few args to syscall");
case 1:
retval = syscall(arg[0]);
break;