mirror of
https://github.com/apache/httpd.git
synced 2025-08-05 16:55:50 +03:00
Add specified user attributes to the environment when using
mod_auth_ldap. This allows you to use mod_include to embed specified user attributes in a page like so: Hello <!--#echo var="AUTHENTICATE_CN"-->, how are you? PR: Obtained from: Submitted by: Reviewed by: git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90775 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -116,12 +116,15 @@ void util_ald_free(const void *ptr)
|
||||
{
|
||||
#if APR_HAS_SHARED_MEMORY
|
||||
if (util_ldap_shm) {
|
||||
apr_shm_free(util_ldap_shm, (void *)ptr);
|
||||
if (ptr)
|
||||
apr_shm_free(util_ldap_shm, (void *)ptr);
|
||||
} else {
|
||||
free((void *)ptr);
|
||||
if (ptr)
|
||||
free((void *)ptr);
|
||||
}
|
||||
#else
|
||||
free((void *)ptr);
|
||||
if (ptr)
|
||||
free((void *)ptr);
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -129,12 +132,12 @@ void *util_ald_alloc(int size)
|
||||
{
|
||||
#if APR_HAS_SHARED_MEMORY
|
||||
if (util_ldap_shm) {
|
||||
return (void *)apr_shm_malloc(util_ldap_shm, size);
|
||||
return (void *)apr_shm_calloc(util_ldap_shm, size);
|
||||
} else {
|
||||
return (void *)malloc(size);
|
||||
return (void *)calloc(sizeof(char), size);
|
||||
}
|
||||
#else
|
||||
return (void *)malloc(size);
|
||||
return (void *)calloc(size);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user