]> granicus.if.org Git - apache/commitdiff
Stop registering a cleanup on each LDAP connection created, this cleanup was
authorEric Covener <covener@apache.org>
Wed, 7 Nov 2007 14:43:26 +0000 (14:43 +0000)
committerEric Covener <covener@apache.org>
Wed, 7 Nov 2007 14:43:26 +0000 (14:43 +0000)
never called because it's registered against pconf in the child. LDAP
connections are created in the child and not shared between children, so no
action should be required at child exit

Additionally, clarify comments around uldap_connection_cleanup()

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

include/util_ldap.h
modules/ldap/util_ldap.c

index fc069aeec9c9c58e30a6fc0d291dd7a777937b5f..5d79387cca493a149e15b58e4807c7ce286ea192 100644 (file)
@@ -190,8 +190,7 @@ APR_DECLARE_OPTIONAL_FN(apr_status_t,uldap_connection_unbind,(void *param));
  * Cleanup a connection to an LDAP server
  * @param ldc A structure containing the expanded details of the server
  *            that was connected.
- * @tip This function is registered with the pool cleanup to close down the
- *      LDAP connections when the server is finished with them.
+ * @tip The connection is unlocked and returned to the list of free connections
  * @fn apr_status_t util_ldap_connection_cleanup(util_ldap_connection_t *ldc)
  */
 APR_DECLARE_OPTIONAL_FN(apr_status_t,uldap_connection_cleanup,(void *param));
index a0900a16e01867a04610b3c346899041bfc8e414..280abadf3fd83de0ad11ecc53153852807b6090e 100644 (file)
@@ -171,9 +171,8 @@ static apr_status_t uldap_connection_unbind(void *param)
 
 
 /*
- * Clean up an LDAP connection by unbinding and unlocking the connection.
- * This function is registered with the pool cleanup function - causing
- * the LDAP connections to be shut down cleanly on graceful restart.
+ * Clean up an LDAP connection by unbinding and unlocking the connection,
+ * causing it to be returned to the list of free connections
  */
 static apr_status_t uldap_connection_cleanup(void *param)
 {
@@ -563,11 +562,6 @@ static util_ldap_connection_t *
         /* save away a copy of the client cert list that is presently valid */
         l->client_certs = apr_array_copy_hdr(l->pool, st->client_certs);
 
-        /* add the cleanup to the pool */
-        apr_pool_cleanup_register(l->pool, l,
-                                  uldap_connection_cleanup,
-                                  apr_pool_cleanup_null);
-
         if (p) {
             p->next = l;
         }