diff options
author | Stefan Metzmacher <metze@samba.org> | 2010-09-22 19:04:58 -0700 |
---|---|---|
committer | Anatoliy Atanasov <anatoliy.atanasov@postpath.com> | 2010-09-23 08:41:05 -0700 |
commit | 224fbbe33fbb4acea1c0907b1b7566d749521a92 (patch) | |
tree | 387376aedbf8b4427a0559b721cbb5262ed9d0c2 /source4 | |
parent | be0ed310b335b5098f2ba475a709c1832de10127 (diff) | |
download | samba-224fbbe33fbb4acea1c0907b1b7566d749521a92.tar.gz samba-224fbbe33fbb4acea1c0907b1b7566d749521a92.tar.bz2 samba-224fbbe33fbb4acea1c0907b1b7566d749521a92.zip |
s4:irpc: use LIBNDR_FLAG_REF_ALLOC for the server side when pulling
The dcerpc server also uses it, so it was surprising that the
IRPC server side doesn't used it.
The reason to have this is that we want to handle error cases
and returns like NT_STATUS_NOT_SUPPORTED sane, without crashing
while marshalling the response.
metze
Signed-off-by: Anatoliy Atanasov <anatoliy.atanasov@postpath.com>
Diffstat (limited to 'source4')
-rw-r--r-- | source4/lib/messaging/messaging.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source4/lib/messaging/messaging.c b/source4/lib/messaging/messaging.c index d880c6336f..724d66af68 100644 --- a/source4/lib/messaging/messaging.c +++ b/source4/lib/messaging/messaging.c @@ -769,6 +769,8 @@ static void irpc_handler_request(struct messaging_context *msg_ctx, r = talloc_zero_size(m->ndr, i->table->calls[m->header.callnum].struct_size); if (r == NULL) goto failed; + m->ndr->flags |= LIBNDR_FLAG_REF_ALLOC; + /* parse the request data */ ndr_err = i->table->calls[i->callnum].ndr_pull(m->ndr, NDR_IN, r); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) goto failed; |