diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-05-27 15:49:13 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-05-27 15:49:13 +0000 |
commit | 9b612d382de382913d3eab12dac986fc5fc21864 (patch) | |
tree | 02415ac36a66f8bee02954d820dac33104775678 /lib/cgi | |
parent | 36276b6f40fe87aec2883a7641a249002a3bb7a9 (diff) | |
download | ruby-9b612d382de382913d3eab12dac986fc5fc21864.tar.gz |
* test/lib/minitest/unit.rb: Use Tempfile#close! instead of
Tempfile#unlink to close file descriptors.
* test/openssl/test_config.rb: Ditto.
* test/ruby/test_io.rb: Ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46189 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/cgi')
-rw-r--r-- | lib/cgi/core.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/cgi/core.rb b/lib/cgi/core.rb index 76b3a24b91..b80e036a86 100644 --- a/lib/cgi/core.rb +++ b/lib/cgi/core.rb @@ -550,7 +550,7 @@ class CGI name = $1 || $2 || '' if body.original_filename.empty? value=body.read.dup.force_encoding(@accept_charset) - body.close(true) if defined?(Tempfile) && body.kind_of?(Tempfile) + body.close! if defined?(Tempfile) && body.kind_of?(Tempfile) (params[name] ||= []) << value unless value.valid_encoding? if @accept_charset_error_block @@ -578,7 +578,7 @@ class CGI if tempfiles tempfiles.each {|t| if t.path - t.close(true) + t.close! end } end |