From bdf4dca50508994284d4a80b08dd73d3a739e8f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Michaj=C5=82ow?= Date: Fri, 24 Nov 2023 07:32:25 +0100 Subject: [PATCH] osdep/io: add PRINTF_ATTRIBUTE for printf overrides --- osdep/io.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/osdep/io.h b/osdep/io.h index db711fb265..ca07bdbfb3 100644 --- a/osdep/io.h +++ b/osdep/io.h @@ -29,6 +29,8 @@ #include #include +#include "compiler.h" + #if HAVE_GLOB_POSIX #include #endif @@ -94,8 +96,8 @@ char *mp_to_utf8(void *talloc_ctx, const wchar_t *s); #include #include -int mp_printf(const char *format, ...); -int mp_fprintf(FILE *stream, const char *format, ...); +int mp_printf(const char *format, ...) PRINTF_ATTRIBUTE(1, 2); +int mp_fprintf(FILE *stream, const char *format, ...) PRINTF_ATTRIBUTE(2, 3); int mp_open(const char *filename, int oflag, ...); int mp_creat(const char *filename, int mode); int mp_rename(const char *oldpath, const char *newpath);