From: Simon McVittie Date: Mon, 2 Feb 2015 17:29:43 +0000 (+0000) Subject: bus: put the printf attribute in the header where it will do more good X-Git-Tag: dbus-1.9.8~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=5b89e2a839b9d778cc9e4bdc156243f826e26b2b;p=thirdparty%2Fdbus.git bus: put the printf attribute in the header where it will do more good Now we can actually notice incorrect format strings in other translation units. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=88810 Reviewed-by: Philip Withnall --- diff --git a/bus/bus.c b/bus/bus.c index f51ee991b..84e6a1fe9 100644 --- a/bus/bus.c +++ b/bus/bus.c @@ -1324,9 +1324,6 @@ bus_context_get_initial_fd_limit (BusContext *context) return context->initial_fd_limit; } -void -bus_context_log (BusContext *context, DBusSystemLogSeverity severity, const char *msg, ...) _DBUS_GNUC_PRINTF (3, 4); - void bus_context_log (BusContext *context, DBusSystemLogSeverity severity, const char *msg, ...) { diff --git a/bus/bus.h b/bus/bus.h index dac6ea5e3..d05c80f01 100644 --- a/bus/bus.h +++ b/bus/bus.h @@ -120,7 +120,7 @@ DBusRLimit * bus_context_get_initial_fd_limit (BusContext void bus_context_log (BusContext *context, DBusSystemLogSeverity severity, const char *msg, - ...); + ...) _DBUS_GNUC_PRINTF (3, 4); dbus_bool_t bus_context_check_security_policy (BusContext *context, BusTransaction *transaction, DBusConnection *sender,