Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:11.4:Update
autofs
autofs-5.0.6-fix-ldap-result-leaks-on-error-pat...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File autofs-5.0.6-fix-ldap-result-leaks-on-error-paths.patch of Package autofs
commit 841023c590621a5794945b3ab16a3d1e24653432 Author: Leonardo Chiquitto <leonardo.lists@gmail.com> Date: Thu Dec 1 15:22:51 2011 +0800 autofs-5.0.6 - Fix LDAP result leaks on error paths According to ldap_search_s(3), the result structure must be freed with ldap_msgfree() even when the search function returned failure. Index: autofs-5.0.5/CHANGELOG =================================================================== --- autofs-5.0.5.orig/CHANGELOG +++ autofs-5.0.5/CHANGELOG @@ -83,6 +83,7 @@ - fix paged query more results check. - fix dumpmaps not reading maps. - fix result null check in read_one_map(). +- fix LDAP result leaks on error paths. 03/09/2009 autofs-5.0.5 ----------------------- Index: autofs-5.0.5/modules/lookup_ldap.c =================================================================== --- autofs-5.0.5.orig/modules/lookup_ldap.c +++ autofs-5.0.5/modules/lookup_ldap.c @@ -346,6 +346,8 @@ static int get_query_dn(unsigned logopt, error(logopt, MODPREFIX "query failed for %s: %s", query, ldap_err2string(rv)); + if (result) + ldap_msgfree(result); free(query); return 0; } @@ -1552,6 +1554,8 @@ int lookup_read_master(struct master *ma error(logopt, MODPREFIX "query failed for %s: %s", query, ldap_err2string(rv)); unbind_ldap_connection(logging, ldap, ctxt); + if (result) + ldap_msgfree(result); free(query); return NSS_STATUS_NOTFOUND; } @@ -2565,6 +2569,8 @@ static int lookup_one(struct autofs_poin if ((rv != LDAP_SUCCESS) || !result) { crit(ap->logopt, MODPREFIX "query failed for %s", query); unbind_ldap_connection(ap->logopt, ldap, ctxt); + if (result) + ldap_msgfree(result); free(query); return CHE_FAIL; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor