* lib/webrick/httpproxy.rb: remvoe useless assigned variables.
* lib/webrick/httpservlet/cgihandler.rb: ditto. * lib/webrick/httpservlet/erbhandler.rb: ditto. * lib/webrick/server.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46560 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
46724873b0
commit
c9134128cb
@ -1,3 +1,10 @@
|
|||||||
|
Thu Jun 26 17:57:57 2014 SHIBATA Hiroshi <shibata.hiroshi@gmail.com>
|
||||||
|
|
||||||
|
* lib/webrick/httpproxy.rb: remvoe useless assigned variables.
|
||||||
|
* lib/webrick/httpservlet/cgihandler.rb: ditto.
|
||||||
|
* lib/webrick/httpservlet/erbhandler.rb: ditto.
|
||||||
|
* lib/webrick/server.rb: ditto.
|
||||||
|
|
||||||
Thu Jun 26 08:28:01 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Thu Jun 26 08:28:01 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* hash.c (env_select): fix memory leak and crash on Windows, make
|
* hash.c (env_select): fix memory leak and crash on Windows, make
|
||||||
|
@ -203,7 +203,7 @@ module WEBrick
|
|||||||
ua.syswrite(buf)
|
ua.syswrite(buf)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
rescue => ex
|
rescue
|
||||||
os.close
|
os.close
|
||||||
@logger.debug("CONNECT #{host}:#{port}: closed")
|
@logger.debug("CONNECT #{host}:#{port}: closed")
|
||||||
end
|
end
|
||||||
|
@ -41,9 +41,6 @@ module WEBrick
|
|||||||
# :stopdoc:
|
# :stopdoc:
|
||||||
|
|
||||||
def do_GET(req, res)
|
def do_GET(req, res)
|
||||||
data = nil
|
|
||||||
status = -1
|
|
||||||
|
|
||||||
cgi_in = IO::popen(@cgicmd, "wb")
|
cgi_in = IO::popen(@cgicmd, "wb")
|
||||||
cgi_out = Tempfile.new("webrick.cgiout.", @tempdir, mode: IO::BINARY)
|
cgi_out = Tempfile.new("webrick.cgiout.", @tempdir, mode: IO::BINARY)
|
||||||
cgi_out.set_encoding("ASCII-8BIT")
|
cgi_out.set_encoding("ASCII-8BIT")
|
||||||
|
@ -56,7 +56,7 @@ module WEBrick
|
|||||||
res.body = evaluate(ERB.new(data), req, res)
|
res.body = evaluate(ERB.new(data), req, res)
|
||||||
res['content-type'] ||=
|
res['content-type'] ||=
|
||||||
HTTPUtils::mime_type(@script_filename, @config[:MimeTypes])
|
HTTPUtils::mime_type(@script_filename, @config[:MimeTypes])
|
||||||
rescue StandardError => ex
|
rescue StandardError
|
||||||
raise
|
raise
|
||||||
rescue Exception => ex
|
rescue Exception => ex
|
||||||
@logger.error(ex)
|
@logger.error(ex)
|
||||||
|
@ -288,7 +288,7 @@ module WEBrick
|
|||||||
Utils::set_non_blocking(sock)
|
Utils::set_non_blocking(sock)
|
||||||
Utils::set_close_on_exec(sock)
|
Utils::set_close_on_exec(sock)
|
||||||
rescue Errno::ECONNRESET, Errno::ECONNABORTED,
|
rescue Errno::ECONNRESET, Errno::ECONNABORTED,
|
||||||
Errno::EPROTO, Errno::EINVAL => ex
|
Errno::EPROTO, Errno::EINVAL
|
||||||
rescue StandardError => ex
|
rescue StandardError => ex
|
||||||
msg = "#{ex.class}: #{ex.message}\n\t#{ex.backtrace[0]}"
|
msg = "#{ex.class}: #{ex.message}\n\t#{ex.backtrace[0]}"
|
||||||
@logger.error msg
|
@logger.error msg
|
||||||
|
Loading…
x
Reference in New Issue
Block a user