]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
*) mod_http2: optimize authority construction on upgraded
authorStefan Eissing <icing@apache.org>
Fri, 18 Feb 2022 09:31:30 +0000 (09:31 +0000)
committerStefan Eissing <icing@apache.org>
Fri, 18 Feb 2022 09:31:30 +0000 (09:31 +0000)
     h1 requests.
     [Ruediger Pluem]

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

modules/http2/h2_request.c

index 7899f282d46ef2cab50ec8a4490fb03f28eec786..69086e0220b3b53201ccc75b5b7079f824ae5dc4 100644 (file)
@@ -97,7 +97,7 @@ apr_status_t h2_request_rcreate(h2_request **preq, apr_pool_t *pool,
     if (!ap_strchr_c(authority, ':')) {
         if (r->parsed_uri.port_str) {
             /* Yes, it was there, add it again. */
-            authority = apr_psprintf(pool, "%s:%s", authority, r->parsed_uri.port_str);
+            authority = apr_pstrcat(pool, authority, ":", r->parsed_uri.port_str, NULL);
         }
         else if (!r->parsed_uri.hostname && r->server && r->server->port) {
             /* If there was no hostname in the parsed URL, the URL was relative.