From 72569b4f1eb90d56a032e9d12fd97a5531a2467c Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 20 Oct 2003 19:04:06 +0000 Subject: Merge Volker's fix. It's a perfectly valid condition to have zero alias members. Jeremy. (This used to be commit aa7fb71357921c9d1fa1d32e5eaff912428e4fdf) --- source3/rpc_client/cli_samr.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source3/rpc_client') diff --git a/source3/rpc_client/cli_samr.c b/source3/rpc_client/cli_samr.c index f985ee9979..e5e67f39dc 100644 --- a/source3/rpc_client/cli_samr.c +++ b/source3/rpc_client/cli_samr.c @@ -865,6 +865,12 @@ NTSTATUS cli_samr_query_aliasmem(struct cli_state *cli, TALLOC_CTX *mem_ctx, *num_mem = r.num_sids; + if (*num_mem == 0) { + *sids = NULL; + result = NT_STATUS_OK; + goto done; + } + if (!(*sids = talloc(mem_ctx, sizeof(DOM_SID) * *num_mem))) { result = NT_STATUS_UNSUCCESSFUL; goto done; -- cgit