git.samba.org
/
metze
/
samba
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7e678ef
)
s3-pdb_ldap: fix memleak.
author
Günther Deschner
<gd@samba.org>
Wed, 28 Apr 2010 22:52:17 +0000
(
00:52
+0200)
committer
Günther Deschner
<gd@samba.org>
Thu, 29 Apr 2010 10:05:42 +0000
(12:05 +0200)
Guenther
source3/passdb/pdb_ldap.c
patch
|
blob
|
history
diff --git
a/source3/passdb/pdb_ldap.c
b/source3/passdb/pdb_ldap.c
index 4ff718ebdb2006fc38fc247e499197d597652e5f..a66ae9791ac6abafe0864a8b52af5a1cdaa0aea1 100644
(file)
--- a/
source3/passdb/pdb_ldap.c
+++ b/
source3/passdb/pdb_ldap.c
@@
-3995,14
+3995,14
@@
static NTSTATUS ldapsam_get_account_policy_from_ldap(struct pdb_methods *methods
attrs[0] = policy_attr;
attrs[1] = NULL;
- filter = talloc_asprintf(
NULL
, "(objectClass=%s)", LDAP_OBJ_DOMINFO);
+ filter = talloc_asprintf(
talloc_tos()
, "(objectClass=%s)", LDAP_OBJ_DOMINFO);
if (filter == NULL) {
return NT_STATUS_NO_MEMORY;
}
rc = smbldap_search(ldap_state->smbldap_state, ldap_state->domain_dn,
LDAP_SCOPE_BASE, filter, attrs, 0,
&result);
-
+ TALLOC_FREE(filter);
if (rc != LDAP_SUCCESS) {
return ntstatus;
}