Project

General

Profile

Bug #7650 ยป generic_request2.patch

hsbt (Hiroshi SHIBATA), 01/05/2013 07:44 PM

View differences:

lib/net/http/generic_request.rb
99 99
  #
100 100

  
101 101
  def exec(sock, ver, path)   #:nodoc: internal use only
102
    self['host'] = "#{@uri.host}:#{@uri.port}" if @uri
102
    if @uri && @uri.port != @uri.default_port
103
      self['host'] = "#{@uri.host}:#{@uri.port}"
104
    end
103 105

  
104 106
    if @body
105 107
      send_request_with_body sock, ver, path, @body