From d1cfbd51b5f6e4246cec86ce3c9b7b1cde2f860a Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Fri, 2 Mar 2001 15:34:15 +0000 Subject: remade the port number stuff so that following locations work and doing intermixed HTTP and FTP persistant connections also work! --- lib/http.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/http.c') diff --git a/lib/http.c b/lib/http.c index 641373ae2..a77cc0e45 100644 --- a/lib/http.c +++ b/lib/http.c @@ -465,14 +465,14 @@ CURLcode Curl_http(struct connectdata *conn) /* if ptr_host is already set, it is OK since we only re-use connections to the very same host and port */ - if(((conn->protocol&PROT_HTTPS) && (data->remote_port == PORT_HTTPS)) || - (!(conn->protocol&PROT_HTTPS) && (data->remote_port == PORT_HTTP)) ) + if(((conn->protocol&PROT_HTTPS) && (conn->remote_port == PORT_HTTPS)) || + (!(conn->protocol&PROT_HTTPS) && (conn->remote_port == PORT_HTTP)) ) /* If (HTTPS on port 443) OR (non-HTTPS on port 80) then don't include the port number in the host string */ conn->allocptr.host = aprintf("Host: %s\r\n", host); else conn->allocptr.host = aprintf("Host: %s:%d\r\n", host, - data->remote_port); + conn->remote_port); } if(!checkheaders(data, "Pragma:")) -- cgit v1.2.3