diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2001-06-19 04:35:17 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2001-06-19 04:35:17 +0000 |
commit | d4418a4b5b7c02a85455f5f1f0627b97364dba25 (patch) | |
tree | 98247086ea05415f034f0b5a0e6cc97163f47be2 /io.c | |
parent | f043d2f971d97ba5b2dfdf3f93e00accf8a3d3ad (diff) | |
download | ruby-d4418a4b5b7c02a85455f5f1f0627b97364dba25.tar.gz ruby-d4418a4b5b7c02a85455f5f1f0627b97364dba25.tar.xz ruby-d4418a4b5b7c02a85455f5f1f0627b97364dba25.zip |
* eval.c (rb_f_require): searches ".rb" and ".so" at the same
time. previous behavior (search ".rb", then ".so") has a
security risk (ruby-bugs#PR140).
* array.c (rb_ary_to_ary): new function to replace internal
rb_Array(), which never calls to_a, but to_ary (rb_Array() might
call both). [new]
* regex.c (PUSH_FAILURE_POINT): push option status again.
* regex.c (re_compile_pattern): avoid pushing unnecessary
option_set.
* eval.c (rb_load): tainted string is OK if wrapped *and*
$SAFE >= 4.
* eval.c (rb_thread_start_0): should not nail down higher blocks
before preserving original context (i.e. should not alter
original context).
* eval.c (proc_yield): new method equivalent to Proc#call but no
check for number of arguments. [new]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@1526 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -3462,10 +3462,8 @@ opt_i_set(val) VALUE val; { if (ruby_inplace_mode) free(ruby_inplace_mode); - if (!RTEST(val)) { - ruby_inplace_mode = 0; - return; - } + ruby_inplace_mode = 0; + if (!RTEST(val)) return; StringValue(val); ruby_inplace_mode = strdup(RSTRING(val)->ptr); } |