diff options
author | Günther Deschner <gd@samba.org> | 2009-04-14 00:01:03 +0200 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2009-04-17 17:27:32 +0200 |
commit | 6900d61d369961e0c11e590ccdc102169f21cef3 (patch) | |
tree | 50fd868c2c4e98810440333fd94e7bf53c612a63 | |
parent | 5e563ee508d0b3cc87d72ad52d777946ee0537b1 (diff) | |
download | samba-6900d61d369961e0c11e590ccdc102169f21cef3.tar.gz samba-6900d61d369961e0c11e590ccdc102169f21cef3.tar.bz2 samba-6900d61d369961e0c11e590ccdc102169f21cef3.zip |
s3-spoolss: add support for _spoolss_EnumPrinterDrivers() level 6.
Guenther
-rw-r--r-- | source3/rpc_server/srv_spoolss_nt.c | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c index 17ddafa038..251415adcb 100644 --- a/source3/rpc_server/srv_spoolss_nt.c +++ b/source3/rpc_server/srv_spoolss_nt.c @@ -5008,7 +5008,7 @@ static WERROR fill_printer_driver_info6(TALLOC_CTX *mem_ctx, } else { r->help_file = talloc_strdup(mem_ctx, ""); } - W_ERROR_HAVE_NO_MEMORY(r->config_file); + W_ERROR_HAVE_NO_MEMORY(r->help_file); r->monitor_name = talloc_strdup(mem_ctx, driver->info_3->monitorname); W_ERROR_HAVE_NO_MEMORY(r->monitor_name); @@ -6796,6 +6796,10 @@ static WERROR enumprinterdrivers_level(TALLOC_CTX *mem_ctx, result = fill_printer_driver_info5(info, &info[count+i].info5, &driver, servername); break; + case 6: + result = fill_printer_driver_info6(info, &info[count+i].info6, + &driver, servername); + break; default: result = WERR_UNKNOWN_LEVEL; break; @@ -6896,6 +6900,21 @@ static WERROR enumprinterdrivers_level5(TALLOC_CTX *mem_ctx, info_p, count); } +/**************************************************************************** + Enumerates all printer drivers at level 6. +****************************************************************************/ + +static WERROR enumprinterdrivers_level6(TALLOC_CTX *mem_ctx, + const char *servername, + const char *architecture, + union spoolss_DriverInfo **info_p, + uint32_t *count) +{ + return enumprinterdrivers_level(mem_ctx, servername, architecture, 6, + info_p, count); +} + + /**************************************************************** _spoolss_EnumPrinterDrivers ****************************************************************/ @@ -6950,6 +6969,11 @@ WERROR _spoolss_EnumPrinterDrivers(pipes_struct *p, r->in.environment, r->out.info, r->out.count); break; + case 6: + result = enumprinterdrivers_level6(p->mem_ctx, cservername, + r->in.environment, + r->out.info, r->out.count); + break; default: return WERR_UNKNOWN_LEVEL; } |