diff options
author | Volker Lendecke <vl@samba.org> | 2018-01-17 14:38:41 +0100 |
---|---|---|
committer | Ralph Boehme <slow@samba.org> | 2018-01-17 19:24:11 +0100 |
commit | e4f62d4e4b91395d46c99c2a5313b0536793cca7 (patch) | |
tree | c9301f679ae0cc6b7d26e3dbf5c98666aac8ae80 | |
parent | 0edce86e97a49f4bd79f4431015ac2b788105e46 (diff) | |
download | samba-e4f62d4e4b91395d46c99c2a5313b0536793cca7.tar.gz |
pdb: Fix CID 1427624 Resource leak
It's not exactly a resource leak (we only really realloc if we shrink
dramatically), but assigning the result from tdb_realloc looks nicer.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
-rw-r--r-- | source3/passdb/pdb_samba_dsdb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/passdb/pdb_samba_dsdb.c b/source3/passdb/pdb_samba_dsdb.c index 16a7a85bdfd..b06267b2d64 100644 --- a/source3/passdb/pdb_samba_dsdb.c +++ b/source3/passdb/pdb_samba_dsdb.c @@ -2959,7 +2959,7 @@ static NTSTATUS pdb_samba_dsdb_enum_trusteddoms(struct pdb_methods *m, domains[di++] = d; } - talloc_realloc(domains, domains, struct trustdom_info *, di); + domains = talloc_realloc(domains, domains, struct trustdom_info *, di); *_domains = talloc_move(mem_ctx, &domains); *_num_domains = di; TALLOC_FREE(tmp_ctx); |