From d9c59a7c8ccdb7c0ffdd8c5f9104a94675e49f40 Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Wed, 12 Feb 2020 13:35:42 +0100 Subject: [PATCH] profiler: Add G_GNUC_PRINTF markers to silence warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit I was getting CI failures like: ../gdk/gdkprofiler.c: In function ‘add_markvf’: ../gdk/gdkprofiler.c:111:3: error: function ‘add_markvf’ might be a candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format] --- gdk/gdkprofiler.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gdk/gdkprofiler.c b/gdk/gdkprofiler.c index 4d122b7b91..4617d9a7e3 100644 --- a/gdk/gdkprofiler.c +++ b/gdk/gdkprofiler.c @@ -100,6 +100,12 @@ gdk_profiler_add_mark (gint64 start, "gtk", name, message); } +static void add_markvf (gint64 start, + guint64 duration, + const char *name, + const char *format, + va_list args) G_GNUC_PRINTF(4, 0); + static void add_markvf (gint64 start, guint64 duration,