Mark some functions as printf-like to silence some compiler warnings
authorPeter Hutterer <peter.hutterer@who-t.net>
Thu, 22 Jul 2021 05:25:03 +0000 (15:25 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Thu, 22 Jul 2021 23:14:43 +0000 (23:14 +0000)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
test/test-device.c
tools/libinput-debug-tablet.c
tools/libinput-quirks.c

index 2d7ed71ecd35622f5de709d8afd930c7e58c1c07..57631f1ded52270d4c1d3804b358cff8434cab1d 100644 (file)
@@ -1421,6 +1421,7 @@ END_TEST
 
 char *debug_messages[64] = { NULL };
 
+LIBINPUT_ATTRIBUTE_PRINTF(3, 0)
 static void
 debug_log_handler(struct libinput *libinput,
                  enum libinput_log_priority priority,
index ceaee1d1dc9fd610033f0bfd0b37ed7617f07db4..73948de2ecf010080e7289212962121c79e0d142 100644 (file)
@@ -72,6 +72,7 @@ struct context {
        } abs;
 };
 
+LIBINPUT_ATTRIBUTE_PRINTF(1, 2)
 static void
 print_line(const char *format, ...)
 {
index 173e5c22f65d631b7adce37f3758378e9d7c2fdd..047eb041a583b922f003d35f016c733d539362cf 100644 (file)
@@ -35,6 +35,7 @@
 
 static bool verbose = false;
 
+LIBINPUT_ATTRIBUTE_PRINTF(3, 0)
 static void
 log_handler(struct libinput *this_is_null,
            enum libinput_log_priority priority,