diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-09 05:12:31 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-09 05:12:31 +0000 |
| commit | b4c959577a0f91d0d024281379b2e2b22c1b8c00 (patch) | |
| tree | d42d4a46517df98f61b38a594e76a1e823ec672f /include/ruby/ruby.h | |
| parent | 5a413ce4c01b34c46f55df7df97dd7dcea789b76 (diff) | |
| download | ruby-b4c959577a0f91d0d024281379b2e2b22c1b8c00.tar.gz ruby-b4c959577a0f91d0d024281379b2e2b22c1b8c00.tar.xz ruby-b4c959577a0f91d0d024281379b2e2b22c1b8c00.zip | |
* include/ruby/ruby.h (FilePathStringValue): defined. similar to
FilePathValue but no taint check.
* file.c (rb_get_path_no_checksafe): implementation of
FilePathStringValue.
(rb_file_s_basename): use FilePathStringValue.
(rb_file_s_dirname): ditto.
(rb_file_s_extname): ditto.
(rb_file_s_split): ditto.
(rb_file_join): ditto.
* dir.c (file_s_fnmatch): ditto.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include/ruby/ruby.h')
| -rw-r--r-- | include/ruby/ruby.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h index b0b5153b6..d86c990ad 100644 --- a/include/ruby/ruby.h +++ b/include/ruby/ruby.h @@ -326,6 +326,9 @@ void rb_check_safe_str(VALUE); VALUE rb_get_path(VALUE); #define FilePathValue(v) ((v) = rb_get_path(v)) +VALUE rb_get_path_no_checksafe(VALUE); +#define FilePathStringValue(v) ((v) = rb_get_path_no_checksafe(v)) + void rb_secure(int); int rb_safe_level(void); void rb_set_safe_level(int); |
