- fixed print function with va_list argument

This commit is contained in:
alexey.lysiuk 2020-02-09 15:18:56 +02:00
parent edd802e655
commit 79effe2353

View file

@ -107,7 +107,7 @@ namespace MusicIO {
void ZMusic_Print(int type, const char* msg, va_list args) void ZMusic_Print(int type, const char* msg, va_list args)
{ {
static char printbuf[4096]; static char printbuf[4096];
snprintf(printbuf, 4096, msg, args); vsnprintf(printbuf, 4096, msg, args);
if (musicCallbacks.MessageFunc) if (musicCallbacks.MessageFunc)
{ {
musicCallbacks.MessageFunc(type, printbuf); musicCallbacks.MessageFunc(type, printbuf);