Fixed http_client EiffelNet implementation when port is not the default one.

- previously the client was not sending the complete `host:port` but only `host` as `host` http header.
This commit is contained in:
2017-01-26 21:56:21 +01:00
parent 1b24fb63f7
commit 681151e9b9

View File

@@ -257,6 +257,15 @@ feature -- Access
s.append (h_host) s.append (h_host)
else else
s.append (l_host) s.append (l_host)
if l_is_https then
if l_port /= 443 then
s.append_character (':')
s.append_integer (l_port)
end
elseif l_port /= 80 then
s.append_character (':')
s.append_integer (l_port)
end
end end
s.append (http_end_of_header_line) s.append (http_end_of_header_line)
if not headers.has ("Connection") then if not headers.has ("Connection") then