1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

protocol.rb version 1.1.17

o  http.rb:  'Host:' field includes port if port != 80
o  http.rb:  see also 'proxy-connection:' field


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@679 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
aamine 2000-05-05 08:53:06 +00:00
parent fedf48986d
commit 2a34f89e35
2 changed files with 12 additions and 2 deletions

View file

@ -420,7 +420,11 @@ All "key" is case-insensitive.
@http_version = HTTPVersion
@in_header = {}
if sock.port == HTTP.port
@in_header[ 'Host' ] = sock.addr
else
@in_header[ 'Host' ] = sock.addr + ':' + sock.port
end
@in_header[ 'Connection' ] = 'Keep-Alive'
@in_header[ 'Accept' ] = '*/*'
@ -505,6 +509,12 @@ All "key" is case-insensitive.
if tmp and /close/i === tmp then
@socket.read_all dest
@socket.close
else
tmp = resp['proxy-connection']
if tmp and /close/i === tmp then
@socket.read_all dest
@socket.close
end
end
end
end

View file

@ -15,7 +15,7 @@ require 'socket'
module Net
Version = '1.1.16'
Version = '1.1.17'
=begin