]> granicus.if.org Git - apache/commitdiff
Make <If> sections in virtual host context fill in cmd->path so that
authorStefan Fritsch <sf@apache.org>
Wed, 7 Nov 2012 08:29:49 +0000 (08:29 +0000)
committerStefan Fritsch <sf@apache.org>
Wed, 7 Nov 2012 08:29:49 +0000 (08:29 +0000)
other directive notice that they are in a config section.

This fixes LogLevel not working in <If> sections that are not in
Location/Directory/File sections.

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

CHANGES
server/core.c

diff --git a/CHANGES b/CHANGES
index 08dc1983099f4aa8821903486f787cb40589ad4a..ba2aef91a0a604712b2f964d02efd145cf65f75e 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,10 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache 2.5.0
+
+  *) core: Fix directives like LogLevel that need to know if they are invoked
+     at virtual host context or in Directory/Files/Location/If sections to
+     work properly in If sections that are not in a Directory/Files/Location.
+     [Stefan Fritsch]
  
   *) mod_cache_disk: Resolve errors while revalidating disk-cached files on 
      Windows ("...rename tempfile to datafile failed..."). PR 38827
index 82863460b50bc526cad4fa9446ba31f8ead884bf..818ddbfb518cc73826a8142176fce1d7d7725eb7 100644 (file)
@@ -2354,7 +2354,11 @@ static const char *ifsection(cmd_parms *cmd, void *mconfig, const char *arg)
 
     arg = apr_pstrndup(cmd->temp_pool, arg, endp - arg);
 
-
+    /*
+     * Set a dummy value so that other directives notice that they are inside
+     * a config section.
+     */
+    cmd->path = "*If";
     /* Only if not an .htaccess file */
     if (!old_path) {
         cmd->override = OR_ALL|ACCESS_CONF;