From 7fedcb1786bb20f156e01fc49faee353dad360fa Mon Sep 17 00:00:00 2001 From: Alexander Pevzner Date: Thu, 8 Feb 2024 11:49:02 +0300 Subject: [PATCH] Fixed gcc warning MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit In cups/dest.c: dest.c:1830:21: warning: ‘%s’ directive argument is null [-Wformat-overflow=] 1733 | DEBUG_printf(("1cupsGetNamedDest: Using name=\"%s\"...", name)); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This is really true, and gcc was smart enough to deduct it from context. Obviously, we meant to print dest_name here. --- cups/dest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cups/dest.c b/cups/dest.c index 259e37bf08..bedd4e1701 100644 --- a/cups/dest.c +++ b/cups/dest.c @@ -1827,7 +1827,7 @@ cupsGetNamedDest(http_t *http, /* I - Connection to server or @code CUPS_HTT DEBUG_puts("1cupsGetNamedDest: Asking server for default printer..."); } else - DEBUG_printf(("1cupsGetNamedDest: Using name=\"%s\"...", name)); + DEBUG_printf(("1cupsGetNamedDest: Using dest_name=\"%s\"...", dest_name)); } /* -- 2.47.2