s3: Lift the smbd_messaging_context from construct_printer_info7
authorVolker Lendecke <vl@samba.org>
Sun, 8 Aug 2010 12:40:46 +0000 (14:40 +0200)
committerVolker Lendecke <vl@samba.org>
Sun, 8 Aug 2010 14:03:26 +0000 (16:03 +0200)
source3/rpc_server/srv_spoolss_nt.c

index 9341809128ddfac23f0ba7c09a5c2002e55cb019..7ec0162f1a936fd56163ee7528560937a1eeb12c 100644 (file)
@@ -3740,6 +3740,7 @@ static WERROR construct_printer_info6(TALLOC_CTX *mem_ctx,
  ********************************************************************/
 
 static WERROR construct_printer_info7(TALLOC_CTX *mem_ctx,
  ********************************************************************/
 
 static WERROR construct_printer_info7(TALLOC_CTX *mem_ctx,
+                                     struct messaging_context *msg_ctx,
                                      Printer_entry *print_hnd,
                                      struct spoolss_PrinterInfo7 *r,
                                      int snum)
                                      Printer_entry *print_hnd,
                                      struct spoolss_PrinterInfo7 *r,
                                      int snum)
@@ -3755,8 +3756,7 @@ static WERROR construct_printer_info7(TALLOC_CTX *mem_ctx,
                return WERR_NOMEM;
        }
 
                return WERR_NOMEM;
        }
 
-       if (is_printer_published(mem_ctx, server_info,
-                                smbd_messaging_context(),
+       if (is_printer_published(mem_ctx, server_info, msg_ctx,
                                 print_hnd->servername,
                                 lp_servicename(snum), &guid, NULL)) {
                r->guid = talloc_strdup_upper(mem_ctx, GUID_string2(mem_ctx, &guid));
                                 print_hnd->servername,
                                 lp_servicename(snum), &guid, NULL)) {
                r->guid = talloc_strdup_upper(mem_ctx, GUID_string2(mem_ctx, &guid));
@@ -4295,7 +4295,8 @@ WERROR _spoolss_GetPrinter(struct pipes_struct *p,
                                                 &r->out.info->info6, snum);
                break;
        case 7:
                                                 &r->out.info->info6, snum);
                break;
        case 7:
-               result = construct_printer_info7(p->mem_ctx, Printer,
+               result = construct_printer_info7(p->mem_ctx, p->msg_ctx,
+                                                Printer,
                                                 &r->out.info->info7, snum);
                break;
        case 8:
                                                 &r->out.info->info7, snum);
                break;
        case 8: