summaryrefslogtreecommitdiffstats
path: root/modules/proxy/proxy_util.c
diff options
context:
space:
mode:
authorRuediger Pluem <rpluem@apache.org>2006-01-05 14:46:57 +0100
committerRuediger Pluem <rpluem@apache.org>2006-01-05 14:46:57 +0100
commit6afae96259e0e64d8243f07418332136f102dda9 (patch)
treea6e5491190b613243378baed7e573bf8d8dfa3a0 /modules/proxy/proxy_util.c
parent* Correctly signal broken backend connections up the chain also for the ajp (diff)
downloadapache2-6afae96259e0e64d8243f07418332136f102dda9.tar.xz
apache2-6afae96259e0e64d8243f07418332136f102dda9.zip
* If a subrequest has a broken backend also set no_cache for the main request
and ensure that the chunk filter does not sent the last chunk marker in this case. modules/http/chunk_filter.c: Memorize HTTP_BAD_GATEWAY error buckets that had been seen in filter context to ensure that we do not sent the last chunk marker in this case. modules/proxy/proxy_util.c : Set no_cache also for main request if we are a subrequest. Thanks to Joe Orton and André Malo for the "invented unique pointer" trick. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@366181 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'modules/proxy/proxy_util.c')
-rw-r--r--modules/proxy/proxy_util.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/proxy/proxy_util.c b/modules/proxy/proxy_util.c
index da2cc1ffe9..1fa9b2f784 100644
--- a/modules/proxy/proxy_util.c
+++ b/modules/proxy/proxy_util.c
@@ -2137,6 +2137,12 @@ PROXY_DECLARE(void) ap_proxy_backend_broke(request_rec *r,
conn_rec *c = r->connection;
r->no_cache = 1;
+ /*
+ * If this is a subrequest, then prevent also caching of the main
+ * request.
+ */
+ if (r->main)
+ r->main->no_cache = 1;
e = ap_bucket_error_create(HTTP_BAD_GATEWAY, NULL, c->pool,
c->bucket_alloc);
APR_BRIGADE_INSERT_TAIL(brigade, e);