diff options
Diffstat (limited to 'source3/rpc_parse')
-rw-r--r-- | source3/rpc_parse/parse_buffer.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/source3/rpc_parse/parse_buffer.c b/source3/rpc_parse/parse_buffer.c index b8b2c2e9ea..52117dc44b 100644 --- a/source3/rpc_parse/parse_buffer.c +++ b/source3/rpc_parse/parse_buffer.c @@ -47,7 +47,7 @@ BOOL prs_rpcbuffer(const char *desc, prs_struct *ps, int depth, RPC_BUFFER *buff { prs_debug(ps, depth, desc, "prs_rpcbuffer"); depth++; - + /* reading */ if (UNMARSHALLING(ps)) { buffer->size=0; @@ -135,7 +135,12 @@ BOOL prs_rpcbuffer_p(const char *desc, prs_struct *ps, int depth, RPC_BUFFER **b } return True; } - + + /* Coverity paranoia. Buffer must be valid. */ + if (!*buffer) { + return False; + } + return prs_rpcbuffer( desc, ps, depth, *buffer); } |