Project

General

Profile

Bug #10533 » net.http.bug10533.patch

only resume valid sessions - drbrain (Eric Hodel), 11/21/2014 11:00 PM

View differences:

lib/net/http.rb (working copy)
@socket.write(buf)
HTTPResponse.read_new(@socket).value
end
s.session = @ssl_session if @ssl_session
if @ssl_session and
Time.now < @ssl_session.time + @ssl_session.timeout
s.session = @ssl_session if @ssl_session
end
# Server Name Indication (SNI) RFC 3546
s.hostname = @address if s.respond_to? :hostname=
Timeout.timeout(@open_timeout, Net::OpenTimeout) { s.connect }
(1-1/2)