summaryrefslogtreecommitdiff
path: root/source3/rpc_parse
diff options
context:
space:
mode:
Diffstat (limited to 'source3/rpc_parse')
-rw-r--r--source3/rpc_parse/parse_prs.c2
-rw-r--r--source3/rpc_parse/parse_spoolss.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/source3/rpc_parse/parse_prs.c b/source3/rpc_parse/parse_prs.c
index bf36b5b346..71806e422e 100644
--- a/source3/rpc_parse/parse_prs.c
+++ b/source3/rpc_parse/parse_prs.c
@@ -867,7 +867,7 @@ BOOL prs_uint16_post(char *name, prs_struct *ps, int depth, uint16 *data16,
BOOL prs_uint32_pre(char *name, prs_struct *ps, int depth, uint32 *data32, uint32 *offset)
{
*offset = ps->data_offset;
- if (UNMARSHALLING(ps)) {
+ if (UNMARSHALLING(ps) && (data32 != NULL)) {
/* reading. */
return prs_uint32(name, ps, depth, data32);
} else {
diff --git a/source3/rpc_parse/parse_spoolss.c b/source3/rpc_parse/parse_spoolss.c
index 2adfc65eeb..d0a745d095 100644
--- a/source3/rpc_parse/parse_spoolss.c
+++ b/source3/rpc_parse/parse_spoolss.c
@@ -1778,7 +1778,7 @@ BOOL new_smb_io_printer_info_2(char *desc, NEW_BUFFER *buffer, PRINTER_INFO_2 *i
{
uint32 sec_offset;
prs_struct *ps=&buffer->prs;
- int i = 0;
+ uint32 dummy = 0;
prs_debug(ps, depth, desc, "new_smb_io_printer_info_2");
depth++;
@@ -1814,7 +1814,7 @@ BOOL new_smb_io_printer_info_2(char *desc, NEW_BUFFER *buffer, PRINTER_INFO_2 *i
return False;
#if 1 /* JFMTEST */
- if (!prs_uint32_pre("secdesc_ptr ", ps, depth, &i, &sec_offset))
+ if (!prs_uint32_pre("secdesc_ptr ", ps, depth, &dummy, &sec_offset))
return False;
#else
if (!new_smb_io_relsecdesc("secdesc", buffer, depth, &info->secdesc))