summaryrefslogtreecommitdiff
path: root/source3/printing
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2000-11-14 02:14:58 +0000
committerJeremy Allison <jra@samba.org>2000-11-14 02:14:58 +0000
commite0bcc7ff5434e9f858acc6a79d1842d86d37d73e (patch)
tree487d1ab297a54997af71e00f8b0ee0a11cd4687c /source3/printing
parentf77ceb61c07d2ff3cc28d24a873a2209d0c52e0a (diff)
downloadsamba-e0bcc7ff5434e9f858acc6a79d1842d86d37d73e.tar.gz
samba-e0bcc7ff5434e9f858acc6a79d1842d86d37d73e.tar.bz2
samba-e0bcc7ff5434e9f858acc6a79d1842d86d37d73e.zip
printing/nt_printing.c: After long soul searching and making both Andrew and my
life a misery, here is the only possible null driver fix we have found. This *SUCKS*. rpc_server/srv_spoolss_nt.c: Correct printername search. Correct portname reply Correct attributes reply. Removal of unused temp variable. Jeremy. (This used to be commit 06e71c9f8be20b84e33e143c3d0b7904225efb45)
Diffstat (limited to 'source3/printing')
-rw-r--r--source3/printing/nt_printing.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/printing/nt_printing.c b/source3/printing/nt_printing.c
index 15b78032cd..1519faa567 100644
--- a/source3/printing/nt_printing.c
+++ b/source3/printing/nt_printing.c
@@ -1664,11 +1664,13 @@ static uint32 get_a_printer_2_default(NT_PRINTER_INFO_LEVEL_2 **info_ptr, fstrin
snum = lp_servicenumber(sharename);
slprintf(info.servername, sizeof(info.servername), "\\\\%s", global_myname);
- slprintf(info.printername, sizeof(info.printername), "\\\\%s\\%s",
- global_myname, sharename);
fstrcpy(info.sharename, sharename);
fstrcpy(info.portname, SAMBA_PRINTER_PORT_NAME);
fstrcpy(info.drivername, lp_printerdriver(snum));
+ if (*info.drivername == '\0')
+ fstrcpy(info.drivername, "NO DRIVER AVAILABLE");
+
+ slprintf(info.printername, sizeof(info.printername), "\\\\%s\\%s", global_myname, sharename);
pstrcpy(info.comment, "");
fstrcpy(info.printprocessor, "winprint");
fstrcpy(info.datatype, "RAW");