diff options
author | Johannes Schickel | 2013-07-04 14:44:41 +0200 |
---|---|---|
committer | Johannes Schickel | 2013-07-04 14:44:41 +0200 |
commit | d7ff665737b3144b00d4808043402e1317ee234c (patch) | |
tree | b0a8b1b579ad88d692f605d892697380223a6a9d | |
parent | baafae672f3489b0eaf77c22be0c65ba31e6b73d (diff) | |
download | scummvm-rg350-d7ff665737b3144b00d4808043402e1317ee234c.tar.gz scummvm-rg350-d7ff665737b3144b00d4808043402e1317ee234c.tar.bz2 scummvm-rg350-d7ff665737b3144b00d4808043402e1317ee234c.zip |
AUDIO: Fix ReportHandlerScummVM::printDebug in MT32 code.
Formerly it tried to pass 'va_list' as '...' to debug. Now it's first creating
a String containing the output via String::vformat and then passing it
to debug.
Found by buildbot (master-dc). The warning message was:
audio/softsynth/mt32.cpp:65: warning: cannot pass objects of non-POD type
`struct va_list' through `...'; call will abort at runtime
-rw-r--r-- | audio/softsynth/mt32.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/audio/softsynth/mt32.cpp b/audio/softsynth/mt32.cpp index 00d0469356..3281e3bebf 100644 --- a/audio/softsynth/mt32.cpp +++ b/audio/softsynth/mt32.cpp @@ -62,7 +62,8 @@ protected: // Callback for debug messages, in vprintf() format void printDebug(const char *fmt, va_list list) { - debug(4, fmt, list); + Common::String out = Common::String::vformat(fmt, list); + debug(4, out.c_str()); } // Callbacks for reporting various errors and information |