diff options
author | Jeremy Allison <jra@samba.org> | 2000-08-30 00:45:59 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2000-08-30 00:45:59 +0000 |
commit | d407579b94ee2647d1e51c536534024e5c4c51ad (patch) | |
tree | c4a3ae28143ea3bfc4fe11022455b3d85f94c321 /source3/rpc_parse | |
parent | 3b33053b886b88bb7546f77dcdb038fcdc501c6c (diff) | |
download | samba-d407579b94ee2647d1e51c536534024e5c4c51ad.tar.gz samba-d407579b94ee2647d1e51c536534024e5c4c51ad.tar.bz2 samba-d407579b94ee2647d1e51c536534024e5c4c51ad.zip |
Implemented AbortPrinter() from Gerald's Win32 test code. Just purge all
possible printjobs from that printer (I think this is correct).
Added error code returns for print_queue_XXX() functions.
Jeremy.
(This used to be commit 6d081a9017f87f59b7189ba507e211db01c40af5)
Diffstat (limited to 'source3/rpc_parse')
-rw-r--r-- | source3/rpc_parse/parse_spoolss.c | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/source3/rpc_parse/parse_spoolss.c b/source3/rpc_parse/parse_spoolss.c index 54794a7343..60b6eed0c9 100644 --- a/source3/rpc_parse/parse_spoolss.c +++ b/source3/rpc_parse/parse_spoolss.c @@ -1024,6 +1024,41 @@ BOOL make_spoolss_q_closeprinter(SPOOL_Q_CLOSEPRINTER *q_u, POLICY_HND *hnd) /******************************************************************* * read a structure. + * called from static spoolss_q_abortprinter (srv_spoolss.c) + * called from spoolss_abortprinter (cli_spoolss.c) + ********************************************************************/ +BOOL spoolss_io_q_abortprinter(char *desc, SPOOL_Q_ABORTPRINTER *q_u, prs_struct *ps, int depth) +{ + if (q_u == NULL) return False; + + prs_debug(ps, depth, desc, "spoolss_io_q_abortprinter"); + depth++; + + if (!prs_align(ps)) + return False; + + if (!smb_io_pol_hnd("printer handle",&q_u->handle,ps,depth)) + return False; + + return True; +} + +/******************************************************************* + * write a structure. + * called from spoolss_r_abortprinter (srv_spoolss.c) + ********************************************************************/ +BOOL spoolss_io_r_abortprinter(char *desc, SPOOL_R_ABORTPRINTER *r_u, prs_struct *ps, int depth) +{ + prs_debug(ps, depth, desc, "spoolss_io_r_abortprinter"); + depth++; + if(!prs_uint32("status", ps, depth, &r_u->status)) + return False; + + return True; +} + +/******************************************************************* + * read a structure. * called from static spoolss_q_deleteprinter (srv_spoolss.c) * called from spoolss_deleteprinter (cli_spoolss.c) ********************************************************************/ |