]> granicus.if.org Git - apache/commitdiff
FIXME: These changes are just errors from bad merges in the past.
authorRoy T. Fielding <fielding@apache.org>
Thu, 26 Aug 1999 15:17:10 +0000 (15:17 +0000)
committerRoy T. Fielding <fielding@apache.org>
Thu, 26 Aug 1999 15:17:10 +0000 (15:17 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@83773 13f79535-47bb-0310-9956-ffa450edef68

modules/http/http_protocol.c
server/config.c

index 531047f06c82afa7f27e683d94cd25fe99bc42d5..109e948a711f24fe1746c43c5c9dbdb16db28a5a 100644 (file)
@@ -1545,6 +1545,9 @@ API_EXPORT(void) ap_send_http_header(request_rec *r)
         r->sent_bodyct = 1;
         return;
     }
+    else {
+       fixup_vary(r);
+    }
 
     /*
      * Now that we are ready to send a response, we need to combine the two
@@ -1565,9 +1568,6 @@ API_EXPORT(void) ap_send_http_header(request_rec *r)
        r->proto_num = HTTP_VERSION(1,0);
        ap_table_set(r->subprocess_env, "force-response-1.0", "1");
     }
-    else {
-       fixup_vary(r);
-    }
 
     ap_basic_http_header(r);
 
index 9073d3576f76ad157cfb3fd30affc6927a48c76d..8bd91079490aad325567b6924561eb913c16895b 100644 (file)
@@ -1088,28 +1088,27 @@ int ap_parse_htaccess(void **result, request_rec *r, int override,
 
     /* loop through the access names and find the first one */
 
-    while (access_name[0]) {
-        filename = ap_make_full_path(r->pool, d,
-                                     ap_getword_conf(r->pool, &access_name));
-
-        if ((f = ap_pcfg_openfile(r->pool, filename)) != NULL) {
-
-            dc = ap_create_per_dir_config(r->pool);
+    while (!f && access_name[0]) {
+        char * w = ap_getword_conf(r->pool, &access_name);
+        filename = ap_make_full_path(r->pool, d, w);
+       f = ap_pcfg_openfile(r->pool, filename);
+    }
+    if (f) {
+        dc = ap_create_per_dir_config(r->pool);
 
-            parms.config_file = f;
+       parms.config_file = f;
 
-            errmsg = ap_srm_command_loop(&parms, dc);
+       errmsg = ap_srm_command_loop(&parms, dc);
 
-            ap_cfg_closefile(f);
+       ap_cfg_closefile(f);
 
-            if (errmsg) {
-                ap_log_rerror(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO, r,
-                              "%s: %s", filename, errmsg);
-                return HTTP_INTERNAL_SERVER_ERROR;
-            }
-            *result = dc;
-            break;
-        }
+       if (errmsg) {
+           ap_log_rerror(APLOG_MARK, APLOG_ALERT|APLOG_NOERRNO, r,
+                         "%s: %s", filename, errmsg);
+           return HTTP_INTERNAL_SERVER_ERROR;
+       }
+       *result = dc;
+    }
         else if (errno != ENOENT && errno != ENOTDIR) {
             ap_log_rerror(APLOG_MARK, APLOG_CRIT, r,
                           "%s pcfg_openfile: unable to check htaccess file, "