diff options
-rw-r--r-- | source3/rpc_parse/parse_spoolss.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/source3/rpc_parse/parse_spoolss.c b/source3/rpc_parse/parse_spoolss.c index 8050712d97..2663b09381 100644 --- a/source3/rpc_parse/parse_spoolss.c +++ b/source3/rpc_parse/parse_spoolss.c @@ -3817,6 +3817,22 @@ BOOL spoolss_io_q_setprinter(const char *desc, SPOOL_Q_SETPRINTER *q_u, prs_stru return False; if(!prs_uint32("level", ps, depth, &q_u->level)) return False; + + /* check for supported levels and structures we know about */ + + switch ( q_u->level ) { + case 0: + case 2: + case 3: + case 7: + /* supported levels */ + break; + default: + DEBUG(0,("spoolss_io_q_setprinter: unsupported printer info level [%d]\n", + q_u->level)); + return True; + } + if(!spool_io_printer_info_level("", &q_u->info, ps, depth)) return False; |