diff options
author | Max Horn | 2006-03-08 10:00:12 +0000 |
---|---|---|
committer | Max Horn | 2006-03-08 10:00:12 +0000 |
commit | c59ca20ce6d137a28703d29ce11a62b553f007cb (patch) | |
tree | 963efe8132ce083e6def1d4dc3573259bdb25b57 /common/util.h | |
parent | 871c394e285a24d33ad9bd8141b64a76ef48046d (diff) | |
download | scummvm-rg350-c59ca20ce6d137a28703d29ce11a62b553f007cb.tar.gz scummvm-rg350-c59ca20ce6d137a28703d29ce11a62b553f007cb.tar.bz2 scummvm-rg350-c59ca20ce6d137a28703d29ce11a62b553f007cb.zip |
Check format string in calls of debug/error (adapted from patch #1445422)
svn-id: r21139
Diffstat (limited to 'common/util.h')
-rw-r--r-- | common/util.h | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/common/util.h b/common/util.h index fa31278c42..bb93ea8789 100644 --- a/common/util.h +++ b/common/util.h @@ -261,21 +261,20 @@ const Array<EngineDebugLevel> &listSpecialDebugLevels(); } // End of namespace Common - #if defined(__GNUC__) -void CDECL error(const char *s, ...) NORETURN; +void CDECL error(const char *s, ...) GCC_PRINTF(1, 2) NORETURN; #else void CDECL NORETURN error(const char *s, ...); #endif -void CDECL warning(const char *s, ...); +void CDECL warning(const char *s, ...) GCC_PRINTF(1, 2); -void CDECL debug(int level, const char *s, ...); -void CDECL debug(const char *s, ...); -void CDECL debugN(int level, const char *s, ...); +void CDECL debug(int level, const char *s, ...) GCC_PRINTF(2, 3); +void CDECL debug(const char *s, ...) GCC_PRINTF(1, 2); +void CDECL debugN(int level, const char *s, ...) GCC_PRINTF(2, 3); void checkHeap(); -void CDECL debugC(int level, uint32 engine_level, const char *s, ...); +void CDECL debugC(int level, uint32 engine_level, const char *s, ...) GCC_PRINTF(3, 4); extern int gDebugLevel; |