* lib/net/http.rb: should not overwrite Host: header. (Original patch is contributed by sean@ruby-lang.org)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
87239525c1
commit
3eea2999e7
@ -889,7 +889,7 @@ module Net
|
|||||||
if not req.response_body_permitted? and @close_on_empty_response then
|
if not req.response_body_permitted? and @close_on_empty_response then
|
||||||
req['connection'] = 'close'
|
req['connection'] = 'close'
|
||||||
end
|
end
|
||||||
req['host'] = addr_port()
|
req['host'] ||= addr_port()
|
||||||
end
|
end
|
||||||
|
|
||||||
def end_transport( req, res )
|
def end_transport( req, res )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user