]> granicus.if.org Git - apache/commitdiff
After some consideration - Location walk is always required (before and
authorWilliam A. Rowe Jr <wrowe@apache.org>
Sat, 1 Sep 2001 05:21:16 +0000 (05:21 +0000)
committerWilliam A. Rowe Jr <wrowe@apache.org>
Sat, 1 Sep 2001 05:21:16 +0000 (05:21 +0000)
  after any other map_to_storage operations.)  Therefore, initialize any
  NULL r->per_dir_config at this phase (the earliest necessary point.)

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

server/request.c

index 627563d3f4218712d6deec5da3f3613350f9e0e8..b022a777122302bcb2c69700af28efe21ba01513 100644 (file)
@@ -1098,6 +1098,14 @@ AP_DECLARE(int) ap_location_walk(request_rec *r)
     char *entry_uri;
     int j;
 
+    /* If the initial request creation logic failed to reset the
+     * per_dir_config, we will do so here.
+     * ### at this time, only subreq creation fails to do so.
+     */
+    if (!r->per_dir_config)
+        r->per_dir_config = r->server->lookup_defaults;
+    
+
     /* No tricks here, there are no <Locations > to parse in this vhost
      */
     if (!num_loc) {
@@ -1204,9 +1212,6 @@ AP_DECLARE(int) ap_location_walk(request_rec *r)
     /* Merge our per_uri_defaults preconstruct onto the r->per_dir_configs,
      * and note the end result for later optimization.
      */
-    if (!r->per_dir_config)
-        r->per_dir_config = r->server->lookup_defaults;
-    
     if (per_uri_defaults)
         r->per_dir_config = ap_merge_per_dir_configs(r->pool,
                                                      r->per_dir_config,