]> granicus.if.org Git - apache/commitdiff
Merge r1351016 from trunk:
authorJim Jagielski <jim@apache.org>
Thu, 2 Aug 2012 13:08:05 +0000 (13:08 +0000)
committerJim Jagielski <jim@apache.org>
Thu, 2 Aug 2012 13:08:05 +0000 (13:08 +0000)
pass the provider name to parse_require_line as pool userdata

This allows a single C function to implement several authz providers.

Submitted by: sf
Reviewed/backported by: jim

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1368451 13f79535-47bb-0310-9956-ffa450edef68

STATUS
modules/aaa/mod_authz_core.c

diff --git a/STATUS b/STATUS
index 8bfae3be6f4ab8a85a26446772916d24f933a4a2..255e5b9d792f8fd38eb8b0095db0c36146f24218 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -88,12 +88,6 @@ RELEASE SHOWSTOPPERS:
 PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
   [ start all new proposals below, under PATCHES PROPOSED. ]
 
-   * authz: pass the provider name to parse_require_line as pool userdata
-     This allows a single C function to implement several authz providers.
-     trunk patch: http://svn.apache.org/viewvc?view=revision&revision=1351016
-     2.4.x patch: Trunk patch applies.
-     +1: rjung, sf, jim
-
    * event: Simplify handling of MaxConnectionsPerChild.
      trunk patch: http://svn.apache.org/viewvc?view=revision&revision=1361766
      2.4.x patch: Trunk patch applies.
index fee4b3dba43303b3de43280953f0cfa011edf587..d87928254c76213d8cb22635580591f7c88c846a 100644 (file)
@@ -413,8 +413,14 @@ static const char *add_authz_provider(cmd_parms *cmd, void *config,
     section->limited = cmd->limited;
 
     if (section->provider->parse_require_line) {
-        const char *err = section->provider->parse_require_line(cmd, args,
-                                                                &section->provider_parsed_args);
+        const char *err;
+        apr_pool_userdata_setn(section->provider_name,
+                               AUTHZ_PROVIDER_NAME_NOTE,
+                               apr_pool_cleanup_null,
+                               cmd->temp_pool);
+        err = section->provider->parse_require_line(cmd, args,
+                                              &section->provider_parsed_args);
+
         if (err)
             return err;
     }