diff options
Diffstat (limited to 'Source/Core/Common/StringUtil.h')
| -rw-r--r-- | Source/Core/Common/StringUtil.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/Source/Core/Common/StringUtil.h b/Source/Core/Common/StringUtil.h index 46ed382724..7846cbee3d 100644 --- a/Source/Core/Common/StringUtil.h +++ b/Source/Core/Common/StringUtil.h @@ -14,7 +14,14 @@ #include "Common.h" -std::string StringFromFormat(const char* format, ...); +std::string StringFromFormat(const char* format, ...) +#if !defined _WIN32 +// On compilers that support function attributes, this gives StringFromFormat +// the same errors and warnings that printf would give. + __attribute__ ((__format__(printf, 1, 2))) +#endif +; + // Cheap! bool CharArrayFromFormatV(char* out, int outsize, const char* format, va_list args); |
