diff options
Diffstat (limited to 'src/libw32dll')
-rw-r--r-- | src/libw32dll/wine/debugtools.h | 6 | ||||
-rw-r--r-- | src/libw32dll/wine/ext.h | 3 | ||||
-rw-r--r-- | src/libw32dll/wine/win32.c | 13 |
3 files changed, 10 insertions, 12 deletions
diff --git a/src/libw32dll/wine/debugtools.h b/src/libw32dll/wine/debugtools.h index 038c05309..3b342e10c 100644 --- a/src/libw32dll/wine/debugtools.h +++ b/src/libw32dll/wine/debugtools.h @@ -80,11 +80,7 @@ static inline LPCSTR debugstr_w( LPCWSTR s ) { return debugstr_wn( s, 80 ); } #endif #if 0 /* dbg_printf already defined as a macro */ -#ifdef __GNUC__ -extern int dbg_printf(const char *format, ...) __attribute__((format (printf,1,2))); -#else -extern int dbg_printf(const char *format, ...); -#endif +extern int dbg_printf(const char *format, ...) XINE_FORMAT_PRINTF(1,2); #endif #define TRACE_(X) TRACE diff --git a/src/libw32dll/wine/ext.h b/src/libw32dll/wine/ext.h index 7b284ca79..f0f505c4d 100644 --- a/src/libw32dll/wine/ext.h +++ b/src/libw32dll/wine/ext.h @@ -2,6 +2,7 @@ #define loader_ext_h #include "windef.h" +#include "attributes.h" extern LPVOID FILE_dommap( int unix_handle, LPVOID start, DWORD size_high, DWORD size_low, @@ -9,6 +10,6 @@ extern LPVOID FILE_dommap( int unix_handle, LPVOID start, int prot, int flags ); extern int FILE_munmap( LPVOID start, DWORD size_high, DWORD size_low ); extern int wcsnicmp(const unsigned short* s1, const unsigned short* s2, int n); -extern int __attribute__ ((format (printf, 1, 2))) __vprintf( const char *format, ... ); +extern int XINE_FORMAT_PRINTF(1, 2) __vprintf( const char *format, ... ); #endif diff --git a/src/libw32dll/wine/win32.c b/src/libw32dll/wine/win32.c index 4fe1956b7..397779f72 100644 --- a/src/libw32dll/wine/win32.c +++ b/src/libw32dll/wine/win32.c @@ -12,6 +12,7 @@ for DLL to know too much about its environment. ************************************************************/ #include "config.h" +#include "attributes.h" #define QTX @@ -183,7 +184,7 @@ static void longcount_stub(long long* z) int LOADER_DEBUG=1; // active only if compiled with -DDETAILED_OUT //#define DETAILED_OUT -static inline void __attribute__((__format__(__printf__, 1, 2))) dbgprintf(char* fmt, ...) +static inline void XINE_FORMAT_PRINTF(1, 2) dbgprintf(char* fmt, ...) { #ifdef DETAILED_OUT if(LOADER_DEBUG) @@ -3976,7 +3977,7 @@ static void* exp__dllonexit() return NULL; } -static int __attribute__((__format__(__printf__, 2, 3))) expwsprintfA(char* string, char* format, ...) +static int XINE_FORMAT_PRINTF(2, 3) expwsprintfA(char* string, char* format, ...) { va_list va; int result; @@ -3987,7 +3988,7 @@ static int __attribute__((__format__(__printf__, 2, 3))) expwsprintfA(char* stri return result; } -static int __attribute__((__format__(__printf__, 2, 3))) expsprintf(char* str, const char* format, ...) +static int XINE_FORMAT_PRINTF(2, 3) expsprintf(char* str, const char* format, ...) { va_list args; int r; @@ -3997,7 +3998,7 @@ static int __attribute__((__format__(__printf__, 2, 3))) expsprintf(char* str, c va_end(args); return r; } -static int __attribute__((__format__(__printf__, 2, 3))) expsscanf(const char* str, const char* format, ...) +static int XINE_FORMAT_PRINTF(2, 3) expsscanf(const char* str, const char* format, ...) { va_list args; int r; @@ -4013,7 +4014,7 @@ static void* expfopen(const char* path, const char* mode) //return fopen(path, mode); return fdopen(0, mode); // everything on screen } -static int __attribute__((__format__(__printf__, 2, 3)))expfprintf(void* stream, const char* format, ...) +static int XINE_FORMAT_PRINTF(2, 3)expfprintf(void* stream, const char* format, ...) { va_list args; int r = 0; @@ -4026,7 +4027,7 @@ static int __attribute__((__format__(__printf__, 2, 3)))expfprintf(void* stream, return r; } -static int __attribute__((__format__(__printf__, 1, 2))) expprintf(const char* format, ...) +static int XINE_FORMAT_PRINTF(1, 2) expprintf(const char* format, ...) { va_list args; int r; |