diff mbox series

[v2,5/6] vsnprintf: Drop unused const char fmt * in va_format()

Message ID 20250321144822.324050-6-andriy.shevchenko@linux.intel.com (mailing list archive)
State New
Headers show
Series vsprintf: Add __printf attribute to where it's required | expand

Commit Message

Andy Shevchenko March 21, 2025, 2:40 p.m. UTC
va_format() doesn't use original formatting string, drop that
argument as it's done elsewhere in similar cases.

Suggested-by: Rasmus Villemoes <ravi@prevas.dk>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 lib/vsprintf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/lib/vsprintf.c b/lib/vsprintf.c
index 56fe96319292..899e14e4c469 100644
--- a/lib/vsprintf.c
+++ b/lib/vsprintf.c
@@ -1693,7 +1693,7 @@  char *escaped_string(char *buf, char *end, u8 *addr, struct printf_spec spec,
 }
 
 static char *va_format(char *buf, char *end, struct va_format *va_fmt,
-		       struct printf_spec spec, const char *fmt)
+		       struct printf_spec spec)
 {
 	va_list va;
 
@@ -2462,7 +2462,7 @@  char *pointer(const char *fmt, char *buf, char *end, void *ptr,
 	case 'U':
 		return uuid_string(buf, end, ptr, spec, fmt);
 	case 'V':
-		return va_format(buf, end, ptr, spec, fmt);
+		return va_format(buf, end, ptr, spec);
 	case 'K':
 		return restricted_pointer(buf, end, ptr, spec);
 	case 'N':