]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Fixed problem where the port was left at zero on requests instead of
authorGraham Leggett <minfrin@apache.org>
Sat, 7 Apr 2001 12:24:38 +0000 (12:24 +0000)
committerGraham Leggett <minfrin@apache.org>
Sat, 7 Apr 2001 12:24:38 +0000 (12:24 +0000)
being set to the default scheme port 80
PR:
Obtained from:
Reviewed by:

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88746 13f79535-47bb-0310-9956-ffa450edef68

modules/proxy/proxy_http.c

index d08f77a8cc52100fe1912da1232e2da2086f7248..359fe30f62630b9996faa29e8848f20e944c7d0e 100644 (file)
@@ -204,6 +204,9 @@ int ap_proxy_http_handler(request_rec *r, char *url,
        return ap_proxyerror(r, HTTP_BAD_REQUEST,
                             apr_pstrcat(p,"URI cannot be parsed: ", url, NULL));
     }
+    if (!uri.port) {
+       uri.port = ap_default_port_for_scheme(uri.scheme);
+    }
 
     ap_log_error(APLOG_MARK, APLOG_DEBUG|APLOG_NOERRNO, 0, r->server,
                 "proxy: HTTP connecting %s to %s:%d", url, uri.hostname, uri.port);