mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/webrick/httpserver.rb (WEBrick::HTTPServer#run): should
break the loop if the socket reached to EOF. [ruby-talk:142285] * lib/webrick/httpserver.rb (WEBrick::HTTPServer#run): send response without reading the whole request body if keep-alive is diabled. [experimental] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8540 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
6622dfe58f
commit
3894044308
2 changed files with 13 additions and 1 deletions
|
@ -1,3 +1,12 @@
|
|||
Tue May 31 15:52:45 2005 GOTOU Yuuzou <gotoyuzo@notwork.org>
|
||||
|
||||
* lib/webrick/httpserver.rb (WEBrick::HTTPServer#run): should
|
||||
break the loop if the socket reached to EOF. [ruby-talk:142285]
|
||||
|
||||
* lib/webrick/httpserver.rb (WEBrick::HTTPServer#run): send response
|
||||
without reading the whole request body if keep-alive is diabled.
|
||||
[experimental]
|
||||
|
||||
Mon May 30 23:48:29 2005 Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp>
|
||||
|
||||
* ext/tk/lib/tk/macpkg.rb: add PACKAGE_NAME information of Tcl/Tk
|
||||
|
|
|
@ -53,6 +53,7 @@ module WEBrick
|
|||
timeout -= 0.5
|
||||
end
|
||||
raise HTTPStatus::EOFError if timeout <= 0
|
||||
raise HTTPStatus::EOFError if sock.eof?
|
||||
req.parse(sock)
|
||||
res.request_method = req.request_method
|
||||
res.request_uri = req.request_uri
|
||||
|
@ -79,7 +80,9 @@ module WEBrick
|
|||
res.set_error(ex, true)
|
||||
ensure
|
||||
if req.request_line
|
||||
req.fixup()
|
||||
if req.keep_alive? && res.keep_alive?
|
||||
req.fixup()
|
||||
end
|
||||
res.send_response(sock)
|
||||
server.access_log(@config, req, res)
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue