summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2009-08-14 12:48:10 +1000
committerAndrew Bartlett <abartlet@samba.org>2009-08-14 12:48:10 +1000
commit5c3cf58a842a8ddd5dca785bf5464e0788003400 (patch)
tree88fe2df127e3d84e916e48ad808a879911e358bd /source4
parent88fd98b7c4ed41ab6c6ac5a226581e862ae900f3 (diff)
downloadsamba-5c3cf58a842a8ddd5dca785bf5464e0788003400.tar.gz
samba-5c3cf58a842a8ddd5dca785bf5464e0788003400.tar.bz2
samba-5c3cf58a842a8ddd5dca785bf5464e0788003400.zip
s4:ldap_server Don't talloc_steal (with references) in ldap_backend
There may or may not be a need to take a reference to the 'name' in the ldb_map code, but given we seal the whole msg just above here, it makes no senst to steal the name, but not the values. Andrew Bartlett
Diffstat (limited to 'source4')
-rw-r--r--source4/ldap_server/ldap_backend.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/ldap_server/ldap_backend.c b/source4/ldap_server/ldap_backend.c
index 67cc893ff2..d479ff83b4 100644
--- a/source4/ldap_server/ldap_backend.c
+++ b/source4/ldap_server/ldap_backend.c
@@ -419,7 +419,7 @@ static NTSTATUS ldapsrv_SearchRequest(struct ldapsrv_call *call)
ent->attributes = talloc_array(ent_r, struct ldb_message_element, ent->num_attributes);
NT_STATUS_HAVE_NO_MEMORY(ent->attributes);
for (j=0; j < ent->num_attributes; j++) {
- ent->attributes[j].name = talloc_steal(ent->attributes, res->msgs[i]->elements[j].name);
+ ent->attributes[j].name = res->msgs[i]->elements[j].name;
ent->attributes[j].num_values = 0;
ent->attributes[j].values = NULL;
if (req->attributesonly && (res->msgs[i]->elements[j].num_values == 0)) {