From: Volker Lendecke Date: Sun, 8 Aug 2010 08:54:01 +0000 (+0200) Subject: s3: Lift the smbd_messaging_context from winreg_del_driver X-Git-Tag: release-4-0-0alpha13~1486 X-Git-Url: http://git.samba.org/?p=amitay%2Fsamba.git;a=commitdiff_plain;h=d104e37ed12653008301d68a584d76270a558ca4 s3: Lift the smbd_messaging_context from winreg_del_driver --- diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c index 43ae480d24a..4c660374ae5 100644 --- a/source3/rpc_server/srv_spoolss_nt.c +++ b/source3/rpc_server/srv_spoolss_nt.c @@ -1882,6 +1882,7 @@ WERROR _spoolss_DeletePrinterDriver(struct pipes_struct *p, status = winreg_del_driver(p->mem_ctx, p->server_info, + p->msg_ctx, info_win2k, 3); talloc_free(info_win2k); @@ -1892,7 +1893,8 @@ WERROR _spoolss_DeletePrinterDriver(struct pipes_struct *p, } } - status = winreg_del_driver(p->mem_ctx, p->server_info, info, version); + status = winreg_del_driver(p->mem_ctx, p->server_info, p->msg_ctx, + info, version); done: talloc_free(info); @@ -2017,7 +2019,7 @@ WERROR _spoolss_DeletePrinterDriverEx(struct pipes_struct *p, /* remove the Win2k driver first*/ status = winreg_del_driver(info, p->server_info, - info_win2k, 3); + p->msg_ctx, info_win2k, 3); /* this should not have failed---if it did, report to client */ @@ -2037,7 +2039,8 @@ WERROR _spoolss_DeletePrinterDriverEx(struct pipes_struct *p, } } - status = winreg_del_driver(info, p->server_info, info, version); + status = winreg_del_driver(info, p->server_info, p->msg_ctx, info, + version); if (!W_ERROR_IS_OK(status)) { goto done; } diff --git a/source3/rpc_server/srv_spoolss_util.c b/source3/rpc_server/srv_spoolss_util.c index 668fec7bb10..05ee92f65a3 100644 --- a/source3/rpc_server/srv_spoolss_util.c +++ b/source3/rpc_server/srv_spoolss_util.c @@ -4263,6 +4263,7 @@ done: WERROR winreg_del_driver(TALLOC_CTX *mem_ctx, struct auth_serversupplied_info *server_info, + struct messaging_context *msg_ctx, struct spoolss_DriverInfo8 *info8, uint32_t version) { @@ -4284,7 +4285,7 @@ WERROR winreg_del_driver(TALLOC_CTX *mem_ctx, /* test that the key exists */ result = winreg_printer_opendriver(tmp_ctx, server_info, - smbd_messaging_context(), + msg_ctx, info8->driver_name, info8->architecture, version, diff --git a/source3/rpc_server/srv_spoolss_util.h b/source3/rpc_server/srv_spoolss_util.h index ef2d8be518f..6cd75561752 100644 --- a/source3/rpc_server/srv_spoolss_util.h +++ b/source3/rpc_server/srv_spoolss_util.h @@ -559,6 +559,7 @@ WERROR winreg_get_driver(TALLOC_CTX *mem_ctx, WERROR winreg_del_driver(TALLOC_CTX *mem_ctx, struct auth_serversupplied_info *server_info, + struct messaging_context *msg_ctx, struct spoolss_DriverInfo8 *info8, uint32_t version);