diff options
author | Jon TURNEY <jon.turney@dronecode.org.uk> | 2012-10-11 19:32:24 +0100 |
---|---|---|
committer | Jon TURNEY <jon.turney@dronecode.org.uk> | 2012-10-16 22:29:51 +0100 |
commit | 3d6e6a394ea2d5dcb77aa706f751423315d8a7ed (patch) | |
tree | f53d6be1ab734fc41edfc76e020071c48773004f /hw | |
parent | 13fb6b36b8742a79b9768944eee6d1ad66d7e4d9 (diff) |
hw/xwin: Use X_ATTRIBUTE_PRINTF where suggested for winerror.c
Also, fix the typoed name OsVenderVErrorF (sic), so it actually gets prototyped
and remove redundant declarations of it's prototype.
winerror.c: In function ‘OsVendorVErrorF’:
winerror.c:56:5: warning: function might be possible candidate for ‘gnu_printf’ format attribute [-Wmissing-format-attribute]
winerror.c: In function ‘winMessageBoxF’:
winerror.c:104:5: warning: function might be possible candidate for ‘gnu_printf’ format attribute [-Wmissing-format-attribute]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/xwin/InitOutput.c | 5 | ||||
-rw-r--r-- | hw/xwin/win.h | 6 | ||||
-rw-r--r-- | hw/xwin/winerror.c | 4 | ||||
-rw-r--r-- | hw/xwin/winprocarg.c | 4 |
4 files changed, 4 insertions, 15 deletions
diff --git a/hw/xwin/InitOutput.c b/hw/xwin/InitOutput.c index 14ce85294..4bcd3a006 100644 --- a/hw/xwin/InitOutput.c +++ b/hw/xwin/InitOutput.c @@ -77,11 +77,6 @@ static void winClipboardShutdown(void); #endif -#if defined(DDXOSVERRORF) -void - OsVendorVErrorF(const char *pszFormat, va_list va_args); -#endif - static Bool winCheckDisplayNumber(void); diff --git a/hw/xwin/win.h b/hw/xwin/win.h index e632c792c..7b34e84d9 100644 --- a/hw/xwin/win.h +++ b/hw/xwin/win.h @@ -857,11 +857,13 @@ void #ifdef DDXOSVERRORF void - OSVenderVErrorF(const char *pszFormat, va_list va_args); +OsVendorVErrorF(const char *pszFormat, va_list va_args) +_X_ATTRIBUTE_PRINTF(1, 0); #endif void - winMessageBoxF(const char *pszError, UINT uType, ...); +winMessageBoxF(const char *pszError, UINT uType, ...) +_X_ATTRIBUTE_PRINTF(1, 3); #ifdef XWIN_NATIVEGDI /* diff --git a/hw/xwin/winerror.c b/hw/xwin/winerror.c index 56c1e34e7..6645469fc 100644 --- a/hw/xwin/winerror.c +++ b/hw/xwin/winerror.c @@ -36,10 +36,6 @@ #include "win.h" #ifdef DDXOSVERRORF -/* Prototype */ -void - OsVendorVErrorF(const char *pszFormat, va_list va_args); - void OsVendorVErrorF(const char *pszFormat, va_list va_args) { diff --git a/hw/xwin/winprocarg.c b/hw/xwin/winprocarg.c index a5b3c07bf..14056faf0 100644 --- a/hw/xwin/winprocarg.c +++ b/hw/xwin/winprocarg.c @@ -56,10 +56,6 @@ void void winLogVersionInfo(void); -#ifdef DDXOSVERRORF -void OsVendorVErrorF(const char *pszFormat, va_list va_args); -#endif - /* * Process arguments on the command line */ |