diff options
author | Andrew Bartlett <abartlet@samba.org> | 2005-09-21 00:27:10 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:38:33 -0500 |
commit | b5521a818fb6b54e5e719fc28e51f402a94f3529 (patch) | |
tree | d8b21b7601ca4de09328baf27e452984329de0d8 /source4/rpc_server/lsa | |
parent | b1b5e49f98142daae5423aa5bd17421373f4ed7a (diff) | |
download | samba-b5521a818fb6b54e5e719fc28e51f402a94f3529.tar.gz samba-b5521a818fb6b54e5e719fc28e51f402a94f3529.tar.bz2 samba-b5521a818fb6b54e5e719fc28e51f402a94f3529.zip |
r10373: Fix segfault in LookupSids.
Andrew Bartlett
(This used to be commit ddc3a1c79e80e12296c398c42110fc378fb80e00)
Diffstat (limited to 'source4/rpc_server/lsa')
-rw-r--r-- | source4/rpc_server/lsa/dcesrv_lsa.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source4/rpc_server/lsa/dcesrv_lsa.c b/source4/rpc_server/lsa/dcesrv_lsa.c index 2e3f42b272..4222447f01 100644 --- a/source4/rpc_server/lsa/dcesrv_lsa.c +++ b/source4/rpc_server/lsa/dcesrv_lsa.c @@ -1245,6 +1245,7 @@ static NTSTATUS lsa_LookupSids(struct dcesrv_call_state *dce_call, TALLOC_CTX *m r3.in.unknown1 = 0; r3.in.unknown2 = 0; r3.out.count = r->out.count; + r3.out.names = NULL; status = lsa_LookupSids3(dce_call, mem_ctx, &r3); if (dce_call->fault_code != 0) { @@ -1252,6 +1253,11 @@ static NTSTATUS lsa_LookupSids(struct dcesrv_call_state *dce_call, TALLOC_CTX *m } r->out.domains = r3.out.domains; + if (!r3.out.names) { + r->out.names = NULL; + return status; + } + r->out.names = talloc(mem_ctx, struct lsa_TransNameArray); if (r->out.names == NULL) { return NT_STATUS_NO_MEMORY; |