mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
s4:libcli/rap: use talloc_zero() and initialize everything
metze
This commit is contained in:
parent
850b374ded
commit
17781b1c86
@ -30,18 +30,13 @@ struct rap_call *new_rap_cli_call(TALLOC_CTX *mem_ctx, uint16_t callno)
|
||||
{
|
||||
struct rap_call *call;
|
||||
|
||||
call = talloc(mem_ctx, struct rap_call);
|
||||
|
||||
if (call == NULL)
|
||||
call = talloc_zero(mem_ctx, struct rap_call);
|
||||
if (call == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
call->callno = callno;
|
||||
call->rcv_paramlen = 4;
|
||||
call->rcv_datalen = 0;
|
||||
|
||||
call->paramdesc = NULL;
|
||||
call->datadesc = NULL;
|
||||
call->auxdatadesc = NULL;
|
||||
|
||||
call->ndr_push_param = ndr_push_init_ctx(mem_ctx);
|
||||
call->ndr_push_param->flags = RAPNDR_FLAGS;
|
||||
|
Loading…
Reference in New Issue
Block a user