diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-05-12 09:07:57 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-05-12 09:07:57 +0000 |
commit | 9da4f78db46764be6dae5e7e83ff48cbecb3fb23 (patch) | |
tree | c0805e6c95d6396e28e6129d88905c4dee085f4e /file.c | |
parent | 014f2164ed7031a1c31604b290d2ab0cf1deacdc (diff) |
2000-05-12
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@687 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'file.c')
-rw-r--r-- | file.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -25,6 +25,12 @@ #include <unistd.h> #endif +#ifdef HAVE_SYS_FILE_H +# include <sys/file.h> +#else +int flock _((int, int)); +#endif + #ifdef HAVE_SYS_PARAM_H # include <sys/param.h> #else @@ -875,6 +881,7 @@ rb_file_s_chmod(argc, argv) VALUE rest; int mode, n; + rb_secure(2); rb_scan_args(argc, argv, "1*", &vmode, &rest); mode = NUM2INT(vmode); @@ -927,6 +934,7 @@ rb_file_s_chown(argc, argv) struct chown_args arg; int n; + rb_secure(2); rb_scan_args(argc, argv, "2*", &o, &g, &rest); if (NIL_P(o)) { arg.owner = -1; @@ -1377,6 +1385,7 @@ static VALUE rb_file_s_truncate(obj, path, len) VALUE obj, path, len; { + rb_secure(2); Check_SafeStr(path); #ifdef HAVE_TRUNCATE |