diff options
author | Stefan Weil <weil@mail.berlios.de> | 2010-10-22 23:03:30 +0200 |
---|---|---|
committer | Blue Swirl <blauwirbel@gmail.com> | 2010-10-30 08:01:57 +0000 |
commit | f868445a502a75b6ac785dddbcc3233cc5f986b0 (patch) | |
tree | 82d530110ddc60a8dd532af036dbc79de0ce9be9 /qemu-common.h | |
parent | 338b922edd88440ef555f08d6924609915c6f00c (diff) |
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 <blauwirbel@gmail.com>
Signed-off-by: Stefan Weil <weil@mail.berlios.de>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Diffstat (limited to 'qemu-common.h')
-rw-r--r-- | qemu-common.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/qemu-common.h b/qemu-common.h index d31f3661d..3496e4f5b 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 |