1
0
mirror of https://github.com/apache/httpd.git synced 2025-08-08 15:02:10 +03:00

tweak SCRIPT_FILENAME passed to fastcgi backends when a balancer is used.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1646724 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Eric Covener
2014-12-19 14:03:52 +00:00
parent fcfdd8f918
commit 727a07d553
2 changed files with 14 additions and 0 deletions

View File

@@ -1,6 +1,9 @@
-*- coding: utf-8 -*- -*- coding: utf-8 -*-
Changes with Apache 2.5.0 Changes with Apache 2.5.0
*) mod_proxy_fcgi: Remove proxy:balancer:// prefix from SCRIPT_FILENAME
passed to fastcgi backends. [Eric Covener]
*) mod_http: Fix incorrect If-Match handling. PR 57358 *) mod_http: Fix incorrect If-Match handling. PR 57358
[Kunihiko Sakamoto <ksakamoto google.com>] [Kunihiko Sakamoto <ksakamoto google.com>]

View File

@@ -206,10 +206,21 @@ static apr_status_t send_environment(proxy_conn_rec *conn, request_rec *r,
apr_status_t rv; apr_status_t rv;
apr_size_t avail_len, len, required_len; apr_size_t avail_len, len, required_len;
int next_elem, starting_elem; int next_elem, starting_elem;
char *proxyfilename = r->filename;
/* Strip balancer prefix */
if (r->filename && !strncmp(r->filename, "proxy:balancer://", 17)) {
char *newfname = apr_pstrdup(r->pool, r->filename);
newfname += 17;
newfname = ap_strchr(newfname, '/');
r->filename = newfname;
}
ap_add_common_vars(r); ap_add_common_vars(r);
ap_add_cgi_vars(r); ap_add_cgi_vars(r);
r->filename = proxyfilename;
/* XXX are there any FastCGI specific env vars we need to send? */ /* XXX are there any FastCGI specific env vars we need to send? */
/* XXX mod_cgi/mod_cgid use ap_create_environment here, which fills in /* XXX mod_cgi/mod_cgid use ap_create_environment here, which fills in