git.samba.org
/
nivanova
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
be6dc65
)
s3-spoolss: Migrated spoolss_DeletePrinter to cleanup winreg keys.
author
Andreas Schneider
<asn@samba.org>
Thu, 22 Apr 2010 21:52:33 +0000
(23:52 +0200)
committer
Simo Sorce
<idra@samba.org>
Tue, 27 Jul 2010 14:27:09 +0000
(10:27 -0400)
Signed-off-by: Jim McDonough <jmcd@samba.org>
source3/rpc_server/srv_spoolss_nt.c
patch
|
blob
|
history
diff --git
a/source3/rpc_server/srv_spoolss_nt.c
b/source3/rpc_server/srv_spoolss_nt.c
index 0063502cfc3f5e85dd961d430be330fefc5b58a2..cc2a35a5bbff318e8032f17813c426e9254b6c95 100644
(file)
--- a/
source3/rpc_server/srv_spoolss_nt.c
+++ b/
source3/rpc_server/srv_spoolss_nt.c
@@
-1694,6
+1694,7
@@
WERROR _spoolss_DeletePrinter(pipes_struct *p,
{
Printer_entry *Printer = find_printer_index_by_hnd(p, r->in.handle);
WERROR result;
+ int snum;
if (Printer && Printer->document_started) {
struct spoolss_EndDocPrinter e;
@@
-1703,6
+1704,13
@@
WERROR _spoolss_DeletePrinter(pipes_struct *p,
_spoolss_EndDocPrinter(p, &e);
}
+ if (get_printer_snum(p, r->in.handle, &snum, NULL)) {
+ winreg_delete_printer_key(p->mem_ctx,
+ p->server_info,
+ lp_const_servicename(snum),
+ "");
+ }
+
result = delete_printer_handle(p, r->in.handle);
update_c_setprinter(false);