summaryrefslogtreecommitdiff
path: root/source3/rpc_parse/parse_prs.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/rpc_parse/parse_prs.c')
-rw-r--r--source3/rpc_parse/parse_prs.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/source3/rpc_parse/parse_prs.c b/source3/rpc_parse/parse_prs.c
index d34465e8b4..84c9a3abf4 100644
--- a/source3/rpc_parse/parse_prs.c
+++ b/source3/rpc_parse/parse_prs.c
@@ -116,10 +116,9 @@ BOOL prs_read(prs_struct *ps, int fd, size_t len, int timeout)
void prs_mem_free(prs_struct *ps)
{
- if(ps->is_dynamic && (ps->data_p != NULL))
- free(ps->data_p);
+ if(ps->is_dynamic)
+ SAFE_FREE(ps->data_p);
ps->is_dynamic = False;
- ps->data_p = NULL;
ps->buffer_size = 0;
ps->data_offset = 0;
}