From 73e68c38e74a423f03a1f0c7e6a5bf47d5bdb01e Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Wed, 19 May 2021 18:32:27 +0200 Subject: [PATCH] s3:smbd: Initialize command for spools printer control MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ./../source3/smbd/lanman.c: In function ‘api_WPrintQueueCtrl’: ../../source3/smbd/lanman.c:3342:9: error: ‘command’ may be used uninitialized in this function [-Werror=maybe-uninitialized] Signed-off-by: Andreas Schneider Reviewed-by: Ralph Boehme --- source3/smbd/lanman.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c index 92239273c15..9194113e768 100644 --- a/source3/smbd/lanman.c +++ b/source3/smbd/lanman.c @@ -3260,7 +3260,7 @@ static bool api_WPrintQueueCtrl(struct smbd_server_connection *sconn, struct spoolss_SetPrinterInfoCtr info_ctr; struct spoolss_DevmodeContainer devmode_ctr; struct sec_desc_buf secdesc_ctr; - enum spoolss_PrinterControl command; + enum spoolss_PrinterControl command = SPOOLSS_PRINTER_CONTROL_UNPAUSE; if (!str1 || !str2 || !QueueName) { return False;