summaryrefslogtreecommitdiff
path: root/source3/rpc_server/srv_spoolss_nt.c
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2009-02-12 14:18:28 +0100
committerGünther Deschner <gd@samba.org>2009-02-23 16:17:35 +0100
commit5116f50eb82c76bac40c558c00db17be6b56f161 (patch)
treec7f0d03ac29abc2a74b9cf7cafa8270c06bc48b3 /source3/rpc_server/srv_spoolss_nt.c
parent6259fac904641cdc191d866e4cd9936cc68df45e (diff)
downloadsamba-5116f50eb82c76bac40c558c00db17be6b56f161.tar.gz
samba-5116f50eb82c76bac40c558c00db17be6b56f161.tar.bz2
samba-5116f50eb82c76bac40c558c00db17be6b56f161.zip
s3-spoolss: use pidl for _spoolss_RouterRefreshPrinterChangeNotify.
Guenther
Diffstat (limited to 'source3/rpc_server/srv_spoolss_nt.c')
-rw-r--r--source3/rpc_server/srv_spoolss_nt.c44
1 files changed, 21 insertions, 23 deletions
diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c
index eb04cadf40..c351c2fa2b 100644
--- a/source3/rpc_server/srv_spoolss_nt.c
+++ b/source3/rpc_server/srv_spoolss_nt.c
@@ -3794,24 +3794,31 @@ static WERROR printer_notify_info(pipes_struct *p, POLICY_HND *hnd, struct spool
return WERR_OK;
}
-/********************************************************************
- * spoolss_rfnpcnex
- ********************************************************************/
+/****************************************************************
+ _spoolss_RouterRefreshPrinterChangeNotify
+****************************************************************/
-WERROR _spoolss_rfnpcnex( pipes_struct *p, SPOOL_Q_RFNPCNEX *q_u, SPOOL_R_RFNPCNEX *r_u)
+WERROR _spoolss_RouterRefreshPrinterChangeNotify(pipes_struct *p,
+ struct spoolss_RouterRefreshPrinterChangeNotify *r)
{
- POLICY_HND *handle = &q_u->handle;
- SPOOL_NOTIFY_INFO *info = &r_u->info;
+ POLICY_HND *handle = r->in.handle;
+ struct spoolss_NotifyInfo *info;
Printer_entry *Printer=find_printer_index_by_hnd(p, handle);
WERROR result = WERR_BADFID;
- /* we always have a NOTIFY_INFO struct */
- r_u->info_ptr=0x1;
+ /* we always have a spoolss_NotifyInfo struct */
+ info = talloc_zero(p->mem_ctx, struct spoolss_NotifyInfo);
+ if (!info) {
+ result = WERR_NOMEM;
+ goto done;
+ }
+
+ *r->out.info = info;
if (!Printer) {
- DEBUG(2,("_spoolss_rfnpcnex: Invalid handle (%s:%u:%u).\n",
- OUR_HANDLE(handle)));
+ DEBUG(2,("_spoolss_RouterRefreshPrinterChangeNotify: "
+ "Invalid handle (%s:%u:%u).\n", OUR_HANDLE(handle)));
goto done;
}
@@ -3830,8 +3837,10 @@ WERROR _spoolss_rfnpcnex( pipes_struct *p, SPOOL_Q_RFNPCNEX *q_u, SPOOL_R_RFNPCN
Printer->notify.fnpcn = True;
if (Printer->notify.client_connected) {
- DEBUG(10,("_spoolss_rfnpcnex: Saving change value in request [%x]\n", q_u->change));
- Printer->notify.change = q_u->change;
+ DEBUG(10,("_spoolss_RouterRefreshPrinterChangeNotify: "
+ "Saving change value in request [%x]\n",
+ r->in.change_low));
+ Printer->notify.change = r->in.change_low;
}
/* just ignore the SPOOL_NOTIFY_OPTION */
@@ -10553,17 +10562,6 @@ WERROR _spoolss_RouterReplyPrinterEx(pipes_struct *p,
}
/****************************************************************
- _dcesrv_spoolss_RouterRefreshPrinterChangeNotify
-****************************************************************/
-
-WERROR _spoolss_RouterRefreshPrinterChangeNotify(pipes_struct *p,
- struct spoolss_RouterRefreshPrinterChangeNotify *r)
-{
- p->rng_fault_state = true;
- return WERR_NOT_SUPPORTED;
-}
-
-/****************************************************************
_spoolss_44
****************************************************************/