From: Yann Ylavic Date: Mon, 1 Jun 2015 14:06:39 +0000 (+0000) Subject: mod_proxy: follow up to r1681694. X-Git-Tag: 2.5.0-alpha~3116 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0b5aeb0f655098505affaccd1bb54e32e2995863;p=apache mod_proxy: follow up to r1681694. Handle the proxy-error-override note also in mod_proxy_ajp. The note is not needed in mod_proxy_fcgi (which also handles ProxyErrorOverride) since it calls ap_die() by itself, and always returns OK to proxy_handler(). Add a comment about the note where used. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1682907 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/proxy/mod_proxy_ajp.c b/modules/proxy/mod_proxy_ajp.c index fadc656197..ece475ddf6 100644 --- a/modules/proxy/mod_proxy_ajp.c +++ b/modules/proxy/mod_proxy_ajp.c @@ -644,6 +644,11 @@ static int ap_proxy_ajp_request(apr_pool_t *p, request_rec *r, */ rv = r->status; r->status = HTTP_OK; + /* + * prevent proxy_handler() from treating this as an + * internal error. + */ + apr_table_setn(r->notes, "proxy-error-override", "1"); } else { rv = OK; diff --git a/modules/proxy/mod_proxy_http.c b/modules/proxy/mod_proxy_http.c index 6eb9e7a417..f835d14507 100644 --- a/modules/proxy/mod_proxy_http.c +++ b/modules/proxy/mod_proxy_http.c @@ -1719,6 +1719,10 @@ int ap_proxy_http_process_response(apr_pool_t * p, request_rec *r, ap_discard_request_body(backend->r); } proxy_run_detach_backend(r, backend); + /* + * prevent proxy_handler() from treating this as an + * internal error. + */ apr_table_setn(r->notes, "proxy-error-override", "1"); return proxy_status; }