From: Stefan Weil Date: Wed, 13 Oct 2010 18:54:27 +0000 (+0200) Subject: Replace remaining gcc format attributes by macro GCC_FMT_ATTR (format checking) X-Git-Tag: TizenStudio_2.0_p2.3.2~208^2~7046 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2c80e42395bfe0bf291c082f9399431e1ff9d758;p=sdk%2Femulator%2Fqemu.git Replace remaining gcc format attributes by macro GCC_FMT_ATTR (format checking) Replace the remaining format attribute printf by macro GCC_FMT_ATTR which uses gnu_printf (if supported). v2 * Removal of dyngen specific code is now done in a separate patch. * Handle attribute in new ui/spice-display.c, too. Cc: Blue Swirl Signed-off-by: Stefan Weil Signed-off-by: Blue Swirl --- diff --git a/cpu-all.h b/cpu-all.h index 67a3266..11edddc 100644 --- a/cpu-all.h +++ b/cpu-all.h @@ -773,7 +773,7 @@ void cpu_dump_statistics (CPUState *env, FILE *f, int flags); void QEMU_NORETURN cpu_abort(CPUState *env, const char *fmt, ...) - __attribute__ ((__format__ (__printf__, 2, 3))); + GCC_FMT_ATTR(2, 3); extern CPUState *first_cpu; extern CPUState *cpu_single_env; diff --git a/ui/spice-display.c b/ui/spice-display.c index 6702dfd..7b4f5c1 100644 --- a/ui/spice-display.c +++ b/ui/spice-display.c @@ -29,8 +29,7 @@ static int debug = 0; -static void __attribute__((format(printf,2,3))) -dprint(int level, const char *fmt, ...) +static void GCC_FMT_ATTR(2, 3) dprint(int level, const char *fmt, ...) { va_list args;