]> granicus.if.org Git - apache/commitdiff
revert r1780909 and r1773397 ProxyPass ! perdir
authorEric Covener <covener@apache.org>
Wed, 1 Feb 2017 22:11:49 +0000 (22:11 +0000)
committerEric Covener <covener@apache.org>
Wed, 1 Feb 2017 22:11:49 +0000 (22:11 +0000)
r1773397 had a regression and the whole thing is fishy
to shoehorn the current ProxyPass ! syntax into.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1781324 13f79535-47bb-0310-9956-ffa450edef68

modules/proxy/mod_proxy.c

index a1a6a0f22f87da9d91fab3afe1c7109dd7467ecc..ceb2c397391e32c8234ec762c4c8962fb1ec3169 100644 (file)
@@ -788,36 +788,18 @@ static int proxy_trans(request_rec *r)
      */
 
     dconf = ap_get_module_config(r->per_dir_config, &proxy_module);
-    conf = (proxy_server_conf *) ap_get_module_config(r->server->module_config,
-                                                      &proxy_module);
+
     /* short way - this location is reverse proxied? */
     if (dconf->alias) {
         int rv = ap_proxy_trans_match(r, dconf->alias, dconf);
-        if (OK == rv) { 
-            int matches = 0;
-            /* Got a hit. Need to make sure it's not explicitly declined */
-            if (conf->aliases->nelts) {
-                ent = (struct proxy_alias *) conf->aliases->elts;
-                for (i = 0; i < conf->aliases->nelts; i++) {
-                    int rv = ap_proxy_trans_match(r, &ent[i], dconf);
-                    if (OK == rv) matches++;
-                    if (DECLINED == rv) { 
-                        return DECLINED;
-                    }
-                }
-            }
-
-            /* a non !-rule matches in server scope, restore */
-            if (matches > 0) {
-                ap_proxy_trans_match(r, dconf->alias, dconf);
-            }
-            return OK; 
-        }
         if (DONE != rv) {
             return rv;
         }
     }
 
+    conf = (proxy_server_conf *) ap_get_module_config(r->server->module_config,
+                                                      &proxy_module);
+
     /* long way - walk the list of aliases, find a match */
     if (conf->aliases->nelts) {
         ent = (struct proxy_alias *) conf->aliases->elts;