httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From minf...@apache.org
Subject svn commit: r1209916 - in /httpd/httpd/trunk/modules/proxy: mod_proxy_http.c proxy_util.c
Date Sat, 03 Dec 2011 14:39:51 GMT
Author: minfrin
Date: Sat Dec  3 14:39:51 2011
New Revision: 1209916

URL: http://svn.apache.org/viewvc?rev=1209916&view=rev
Log:
mod_proxy: Remove ap_proxy_make_fake_req() from the public API.

Modified:
    httpd/httpd/trunk/modules/proxy/mod_proxy_http.c
    httpd/httpd/trunk/modules/proxy/proxy_util.c

Modified: httpd/httpd/trunk/modules/proxy/mod_proxy_http.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/proxy/mod_proxy_http.c?rev=1209916&r1=1209915&r2=1209916&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/proxy/mod_proxy_http.c (original)
+++ httpd/httpd/trunk/modules/proxy/mod_proxy_http.c Sat Dec  3 14:39:51 2011
@@ -1268,6 +1268,42 @@ static const char *date_canon(apr_pool_t
     return ndate;
 }
 
+static request_rec *make_fake_req(conn_rec *c, request_rec *r)
+{
+    apr_pool_t *pool;
+    request_rec *rp;
+
+    apr_pool_create(&pool, c->pool);
+
+    rp = apr_pcalloc(pool, sizeof(*r));
+
+    rp->pool            = pool;
+    rp->status          = HTTP_OK;
+
+    rp->headers_in      = apr_table_make(pool, 50);
+    rp->subprocess_env  = apr_table_make(pool, 50);
+    rp->headers_out     = apr_table_make(pool, 12);
+    rp->err_headers_out = apr_table_make(pool, 5);
+    rp->notes           = apr_table_make(pool, 5);
+
+    rp->server = r->server;
+    rp->log = r->log;
+    rp->proxyreq = r->proxyreq;
+    rp->request_time = r->request_time;
+    rp->connection      = c;
+    rp->output_filters  = c->output_filters;
+    rp->input_filters   = c->input_filters;
+    rp->proto_output_filters  = c->output_filters;
+    rp->proto_input_filters   = c->input_filters;
+    rp->client_ip = c->peer_ip;
+    rp->client_addr = c->peer_addr;
+
+    rp->request_config  = ap_create_request_config(pool);
+    proxy_run_create_req(r, rp);
+
+    return rp;
+}
+
 static void process_proxy_header(request_rec *r, proxy_dir_conf *c,
                                  const char *key, const char *value)
 {
@@ -1517,7 +1553,7 @@ apr_status_t ap_proxy_http_process_respo
      * filter chain
      */
 
-    backend->r = ap_proxy_make_fake_req(origin, r);
+    backend->r = make_fake_req(origin, r);
     /* In case anyone needs to know, this is a fake request that is really a
      * response.
      */

Modified: httpd/httpd/trunk/modules/proxy/proxy_util.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/proxy/proxy_util.c?rev=1209916&r1=1209915&r2=1209916&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/proxy/proxy_util.c (original)
+++ httpd/httpd/trunk/modules/proxy/proxy_util.c Sat Dec  3 14:39:51 2011
@@ -355,42 +355,6 @@ PROXY_DECLARE(char *)
     return NULL;
 }
 
-PROXY_DECLARE(request_rec *)ap_proxy_make_fake_req(conn_rec *c, request_rec *r)
-{
-    apr_pool_t *pool;
-    request_rec *rp;
-
-    apr_pool_create(&pool, c->pool);
-
-    rp = apr_pcalloc(pool, sizeof(*r));
-
-    rp->pool            = pool;
-    rp->status          = HTTP_OK;
-
-    rp->headers_in      = apr_table_make(pool, 50);
-    rp->subprocess_env  = apr_table_make(pool, 50);
-    rp->headers_out     = apr_table_make(pool, 12);
-    rp->err_headers_out = apr_table_make(pool, 5);
-    rp->notes           = apr_table_make(pool, 5);
-
-    rp->server = r->server;
-    rp->log = r->log;
-    rp->proxyreq = r->proxyreq;
-    rp->request_time = r->request_time;
-    rp->connection      = c;
-    rp->output_filters  = c->output_filters;
-    rp->input_filters   = c->input_filters;
-    rp->proto_output_filters  = c->output_filters;
-    rp->proto_input_filters   = c->input_filters;
-    rp->client_ip = c->peer_ip;
-    rp->client_addr = c->peer_addr;
-
-    rp->request_config  = ap_create_request_config(pool);
-    proxy_run_create_req(r, rp);
-
-    return rp;
-}
-
 PROXY_DECLARE(int) ap_proxyerror(request_rec *r, int statuscode, const char *message)
 {
     const char *uri = ap_escape_html(r->pool, r->uri);



Mime
View raw message