From: Stefan Weil Date: Fri, 22 Oct 2010 21:03:30 +0000 (+0200) Subject: Add fprintf_function for function pointers to fprintf-like functions X-Git-Tag: TizenStudio_2.0_p2.3.2~208^2~7033 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f868445a502a75b6ac785dddbcc3233cc5f986b0;p=sdk%2Femulator%2Fqemu.git Add fprintf_function for function pointers to fprintf-like functions This kind of function pointers is used very often in qemu. The new data type uses format checking with GCC_FMT_ATTR and will be used in later patches. Cc: Blue Swirl Signed-off-by: Stefan Weil Signed-off-by: Blue Swirl --- diff --git a/qemu-common.h b/qemu-common.h index d31f366..3496e4f 100644 --- a/qemu-common.h +++ b/qemu-common.h @@ -81,6 +81,9 @@ struct iovec { #define GCC_FMT_ATTR(n, m) #endif +typedef int (*fprintf_function)(FILE *f, const char *fmt, ...) + GCC_FMT_ATTR(2, 3); + #ifdef _WIN32 #define fsync _commit #define lseek _lseeki64