s3: Lift the smbd_messaging_context from winreg_create_printer
authorVolker Lendecke <vl@samba.org>
Sun, 8 Aug 2010 07:34:23 +0000 (09:34 +0200)
committerVolker Lendecke <vl@samba.org>
Sun, 8 Aug 2010 14:03:16 +0000 (16:03 +0200)
source3/rpc_server/srv_spoolss_nt.c
source3/rpc_server/srv_spoolss_util.c
source3/rpc_server/srv_spoolss_util.h

index 05876a9a4eb640969eff9a0357b2321dd44737ac..545dae2c372a5512f8e4def398fbbcc5512e7925 100644 (file)
@@ -1670,6 +1670,7 @@ WERROR _spoolss_OpenPrinterEx(struct pipes_struct *p,
 
                winreg_create_printer(p->mem_ctx,
                                      p->server_info,
+                                     p->msg_ctx,
                                      Printer->servername,
                                      lp_const_servicename(snum));
 
@@ -3811,6 +3812,7 @@ static WERROR enum_all_printers_info_level(TALLOC_CTX *mem_ctx,
 
                result = winreg_create_printer(mem_ctx,
                                               server_info,
+                                              smbd_messaging_context(),
                                               NULL,
                                               printer);
                if (!W_ERROR_IS_OK(result)) {
index c4c612a729672766cdea30d8aef7e5ca5a791442..c96c19b1be55c2cb9138bb67bb1ca664095d2e05 100644 (file)
@@ -1315,6 +1315,7 @@ static WERROR winreg_printer_ver_to_dword(const char *str, uint64_t *data)
 
 WERROR winreg_create_printer(TALLOC_CTX *mem_ctx,
                             struct auth_serversupplied_info *server_info,
+                            struct messaging_context *msg_ctx,
                             const char *servername,
                             const char *sharename)
 {
@@ -1347,7 +1348,7 @@ WERROR winreg_create_printer(TALLOC_CTX *mem_ctx,
 
        result = winreg_printer_openkey(tmp_ctx,
                                        server_info,
-                                       smbd_messaging_context(),
+                                       msg_ctx,
                                        &winreg_pipe,
                                        path,
                                        "",
@@ -1369,7 +1370,7 @@ WERROR winreg_create_printer(TALLOC_CTX *mem_ctx,
        /* Create the main key */
        result = winreg_printer_openkey(tmp_ctx,
                                        server_info,
-                                       smbd_messaging_context(),
+                                       msg_ctx,
                                        &winreg_pipe,
                                        path,
                                        "",
index 9b79ce5b67abcaf08ad42434500944cabc0d9a69..e3165a07fab15b198bbd6e7d8c4c701447967e70 100644 (file)
@@ -73,6 +73,7 @@ enum spoolss_PrinterInfo2Mask {
 
 WERROR winreg_create_printer(TALLOC_CTX *mem_ctx,
                             struct auth_serversupplied_info *server_info,
+                            struct messaging_context *msg_ctx,
                             const char *servername,
                             const char *sharename);