]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Backport.
authorGraham Leggett <minfrin@apache.org>
Mon, 13 Dec 2021 15:46:50 +0000 (15:46 +0000)
committerGraham Leggett <minfrin@apache.org>
Mon, 13 Dec 2021 15:46:50 +0000 (15:46 +0000)
  *) mod_proxy_connect, mod_proxy: Do not change the status code after we
     already sent it to the client.
     Trunk version of patch:
        https://svn.apache.org/r1895715
     Backport version for 2.4.x of patch:
       https://patch-diff.githubusercontent.com/raw/apache/httpd/pull/283.diff
     Can be applied via apply_backport_pr.sh 283
     +1: rpluem, icing, minfrin

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1895903 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
modules/proxy/mod_proxy_connect.c
modules/proxy/mod_proxy_http.c

diff --git a/CHANGES b/CHANGES
index d3af8ac61278332055765b670ff7804714ce15d5..f001548c1e6da85a8793d88ec43c0c935ba47364 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,9 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache 2.4.52
 
+  *) mod_proxy_connect, mod_proxy: Do not change the status code after we
+     already sent it to the client.
+
   *) mod_http: Correctly sent a 100 Continue status code when sending an interim
      response as result of an Expect: 100-Continue in the request and not the
      current status code of the request. PR 65725 [Ruediger Pluem]
diff --git a/STATUS b/STATUS
index 2585b360924f0851d9f8cec3111d0c52f6690bb8..3dc0e4fb9871c94ccf3ad7ce793651dd81a05676 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -145,14 +145,6 @@ RELEASE SHOWSTOPPERS:
 PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
   [ start all new proposals below, under PATCHES PROPOSED. ]
 
-  *) mod_proxy_connect, mod_proxy: Do not change the status code after we
-     already sent it to the client.
-     Trunk version of patch:
-        https://svn.apache.org/r1895715
-     Backport version for 2.4.x of patch:
-       https://patch-diff.githubusercontent.com/raw/apache/httpd/pull/283.diff
-     Can be applied via apply_backport_pr.sh 283
-     +1: rpluem, icing, minfrin
 
 
 PATCHES PROPOSED TO BACKPORT FROM TRUNK:
index eb6dd7e166d95314c090d061bf35bb01382caefa..2d05d11673544c76a982c8e4279ceb259e6ef492 100644 (file)
@@ -354,8 +354,6 @@ static int proxy_connect_handler(request_rec *r, proxy_worker *worker,
         if (proxyport && !tunnel->replied) {
             return rc;
         }
-        /* Custom log may need this, still */
-        r->status = rc;
     }
 
     /*
index 3e5c05671753c944d1baab5baa534e34373b955d..9109afede239699680b91d708be1ff0c14ad2276 100644 (file)
@@ -1498,20 +1498,6 @@ int ap_proxy_http_process_response(proxy_http_req_t *req)
 
             /* Let proxy tunnel forward everything */
             status = ap_proxy_tunnel_run(tunnel);
-            if (ap_is_HTTP_ERROR(status)) {
-                /* Tunnel always return HTTP_GATEWAY_TIME_OUT on timeout,
-                 * but we can differentiate between client and backend here.
-                 */
-                if (status == HTTP_GATEWAY_TIME_OUT
-                        && tunnel->timeout == client_timeout) {
-                    status = HTTP_REQUEST_TIME_OUT;
-                }
-            }
-            else {
-                /* Update r->status for custom log */
-                status = HTTP_SWITCHING_PROTOCOLS;
-            }
-            r->status = status;
 
             /* We are done with both connections */
             return DONE;