Revision 9c9e7d51 qemu-common.h

b/qemu-common.h
70 70
#include <sys/uio.h>
71 71
#endif
72 72

  
73
#if defined __GNUC__
74
# if (__GNUC__ < 4) || \
75
     defined(__GNUC_MINOR__) && (__GNUC__ == 4) && (__GNUC_MINOR__ < 4)
76
   /* gcc versions before 4.4.x don't support gnu_printf, so use printf. */
77
#  define GCC_ATTR __attribute__((__unused__, format(printf, 1, 2)))
78
#  define GCC_FMT_ATTR(n, m) __attribute__((format(printf, n, m)))
79
# else
80
   /* Use gnu_printf when supported (qemu uses standard format strings). */
81
#  define GCC_ATTR __attribute__((__unused__, format(gnu_printf, 1, 2)))
82
#  define GCC_FMT_ATTR(n, m) __attribute__((format(gnu_printf, n, m)))
83
# endif
84
#else
85
#define GCC_ATTR /**/
86
#define GCC_FMT_ATTR(n, m)
87
#endif
88

  
73 89
#ifdef _WIN32
74 90
#define fsync _commit
75 91
#define lseek _lseeki64

Also available in: Unified diff