From 30d25210a97403c083f7f8babe2eaa4d4cdfc1ad Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Fri, 11 Jun 2010 11:48:37 +0200 Subject: s3-rpc_client: Use the right memory context for array elements. --- source3/rpc_client/cli_lsarpc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source3/rpc_client/cli_lsarpc.c') diff --git a/source3/rpc_client/cli_lsarpc.c b/source3/rpc_client/cli_lsarpc.c index 649200a967..72514e7f5e 100644 --- a/source3/rpc_client/cli_lsarpc.c +++ b/source3/rpc_client/cli_lsarpc.c @@ -225,7 +225,7 @@ static NTSTATUS rpccli_lsa_lookup_sids_noalloc(struct rpc_pipe_client *cli, name = lsa_names.names[i].name.string; if (name) { - (names)[i] = talloc_strdup(mem_ctx, name); + (names)[i] = talloc_strdup(names, name); if ((names)[i] == NULL) { DEBUG(0, ("cli_lsa_lookup_sids_noalloc(): out of memory\n")); result = NT_STATUS_UNSUCCESSFUL; @@ -234,8 +234,8 @@ static NTSTATUS rpccli_lsa_lookup_sids_noalloc(struct rpc_pipe_client *cli, } else { (names)[i] = NULL; } - domains[i] = talloc_strdup( - mem_ctx, dom_name ? dom_name : ""); + domains[i] = talloc_strdup(domains, + dom_name ? dom_name : ""); (types)[i] = lsa_names.names[i].sid_type; if (((domains)[i] == NULL)) { DEBUG(0, ("cli_lsa_lookup_sids_noalloc(): out of memory\n")); -- cgit