summaryrefslogtreecommitdiff
path: root/source3/rpc_parse/parse_buffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/rpc_parse/parse_buffer.c')
-rw-r--r--source3/rpc_parse/parse_buffer.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/rpc_parse/parse_buffer.c b/source3/rpc_parse/parse_buffer.c
index e98822d46e..9a68e547a0 100644
--- a/source3/rpc_parse/parse_buffer.c
+++ b/source3/rpc_parse/parse_buffer.c
@@ -34,8 +34,10 @@ void rpcbuf_init(RPC_BUFFER *buffer, uint32 size, TALLOC_CTX *ctx)
{
buffer->size = size;
buffer->string_at_end = size;
- prs_init(&buffer->prs, size, ctx, MARSHALL);
- buffer->struct_start = prs_offset(&buffer->prs);
+ if (prs_init(&buffer->prs, size, ctx, MARSHALL))
+ buffer->struct_start = prs_offset(&buffer->prs);
+ else
+ buffer->struct_start = NULL;
}
/*******************************************************************