From: Bradley Nicholes Date: Mon, 28 Feb 2005 23:25:26 +0000 (+0000) Subject: If the search fails due to a bad connection, make sure that we unbind the connection... X-Git-Tag: 2.1.4~27 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=803296f97ca1ba2d6eeac886ebfc6c8de93dad42;p=apache If the search fails due to a bad connection, make sure that we unbind the connection so that it will be recreated the next time it is used. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@155713 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/ldap/util_ldap.c b/modules/ldap/util_ldap.c index 09bcd9fa49..3a561fa85c 100644 --- a/modules/ldap/util_ldap.c +++ b/modules/ldap/util_ldap.c @@ -1118,9 +1118,9 @@ start_over: if ((result = ldap_search_ext_s(ldc->ldap, (char *)basedn, scope, (char *)filter, attrs, 0, - NULL, NULL, - NULL, -1, &res)) == LDAP_SERVER_DOWN) { + NULL, NULL, NULL, -1, &res)) == LDAP_SERVER_DOWN) { ldc->reason = "ldap_search_ext_s() for user failed with server down"; + util_ldap_connection_unbind(ldc); goto start_over; }