httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cove...@apache.org
Subject svn commit: r1197853 - in /httpd/httpd/trunk: CHANGES modules/lua/mod_lua.c
Date Sat, 05 Nov 2011 01:08:05 GMT
Author: covener
Date: Sat Nov  5 01:08:05 2011
New Revision: 1197853

URL: http://svn.apache.org/viewvc?rev=1197853&view=rev
Log:
quick handlers and translate_name in lua can't be keyed off 
Directory/Filename/htaccess


Modified:
    httpd/httpd/trunk/CHANGES
    httpd/httpd/trunk/modules/lua/mod_lua.c

Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=1197853&r1=1197852&r2=1197853&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Sat Nov  5 01:08:05 2011
@@ -12,6 +12,11 @@ Changes with Apache 2.3.15
      PR 51714. [Stefan Fritsch, Jim Jagielski, Ruediger Pluem, Eric Covener,
      <lowprio20 gmail.com>]
 
+  *) mod_lua: Prevent early Lua hooks (LuaHookTranslateName and 
+     LuaHookQuickHandler) from being configured in <Directory>, <Files>, 
+     and htaccess where the configuration would have been ignored.
+     [Eric Covener]
+
   *) mod_lua: Resolve "attempt to index local 'r' (a userdata value)" errors
      in LuaMapHandler scripts [Eric Covener]
 

Modified: httpd/httpd/trunk/modules/lua/mod_lua.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/lua/mod_lua.c?rev=1197853&r1=1197852&r2=1197853&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/lua/mod_lua.c (original)
+++ httpd/httpd/trunk/modules/lua/mod_lua.c Sat Nov  5 01:08:05 2011
@@ -619,6 +619,11 @@ static const char *register_translate_na
                                                 const char *file,
                                                 const char *function)
 {
+    const char *err = ap_check_cmd_context(cmd, NOT_IN_DIRECTORY|NOT_IN_FILES|
+                                           NOT_IN_HTACCESS);
+    if (err) {
+        return err;
+    }
     return register_named_file_function_hook("translate_name", cmd, _cfg,
                                              file, function);
 }
@@ -626,6 +631,11 @@ static const char *register_translate_na
 static const char *register_translate_name_block(cmd_parms *cmd, void *_cfg,
                                                  const char *line)
 {
+    const char *err = ap_check_cmd_context(cmd, NOT_IN_DIRECTORY|NOT_IN_FILES|
+                                                NOT_IN_HTACCESS);
+    if (err) {
+        return err;
+    }
     return register_named_block_function_hook("translate_name", cmd, _cfg,
                                               line);
 }
@@ -724,12 +734,23 @@ static const char *register_insert_filte
 static const char *register_quick_hook(cmd_parms *cmd, void *_cfg,
                                        const char *file, const char *function)
 {
+    const char *err = ap_check_cmd_context(cmd, NOT_IN_DIRECTORY|NOT_IN_FILES|
+                                                NOT_IN_HTACCESS);
+    if (err) {
+        return err;
+    }
     return register_named_file_function_hook("quick", cmd, _cfg, file,
                                              function);
 }
 static const char *register_quick_block(cmd_parms *cmd, void *_cfg,
                                         const char *line)
 {
+    const char *err = ap_check_cmd_context(cmd, NOT_IN_DIRECTORY|NOT_IN_FILES|
+                                                NOT_IN_HTACCESS);
+    if (err) {
+        return err;
+    }
+ 
     return register_named_block_function_hook("quick", cmd, _cfg,
                                               line);
 }



Mime
View raw message