From 08bd5f6d68e2b55a3b4133edecce458269fb9e0f Mon Sep 17 00:00:00 2001 From: Jeremie Roy Date: Wed, 22 May 2013 19:12:54 +0200 Subject: [PATCH] fix vsnwprintf under MSVC --- include/bx/string.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/bx/string.h b/include/bx/string.h index 3c57cbc..2d044cb 100644 --- a/include/bx/string.h +++ b/include/bx/string.h @@ -189,7 +189,7 @@ namespace bx inline int32_t vsnwprintf(wchar_t* _str, size_t _count, const wchar_t* _format, va_list _argList) { #if BX_COMPILER_MSVC - int32_t len = ::_vsnwprintf_s(_str, _count*sizeof(wchar_t), _count, _format, _argList); + int32_t len = ::_vsnwprintf_s(_str, _count, _count, _format, _argList); return -1 == len ? ::_vscwprintf(_format, _argList) : len; #elif defined(__MINGW32__) return ::vsnwprintf(_str, _count, _format, _argList);