mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
winbind: Save lines with talloc_asprintf_addbuf()
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
f25b6de771
commit
4156d37db1
@ -99,19 +99,12 @@ static TLDAPRC get_attrnames_by_oids(struct tldap_context *ld,
|
||||
size_t num_msgs;
|
||||
|
||||
filter = talloc_strdup(mem_ctx, "(|");
|
||||
if (filter == NULL) {
|
||||
return TLDAP_NO_MEMORY;
|
||||
}
|
||||
|
||||
for (i=0; i<num_oids; i++) {
|
||||
filter = talloc_asprintf_append_buffer(
|
||||
filter, "(attributeId=%s)", oids[i]);
|
||||
if (filter == NULL) {
|
||||
return TLDAP_NO_MEMORY;
|
||||
}
|
||||
talloc_asprintf_addbuf(&filter, "(attributeId=%s)", oids[i]);
|
||||
}
|
||||
talloc_asprintf_addbuf(&filter, ")");
|
||||
|
||||
filter = talloc_asprintf_append_buffer(filter, ")");
|
||||
if (filter == NULL) {
|
||||
return TLDAP_NO_MEMORY;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user