mirror of
https://github.com/bkaradzic/bx.git
synced 2026-02-17 20:52:37 +01:00
Cleanup.
This commit is contained in:
@@ -1150,38 +1150,6 @@ namespace bx
|
||||
return size;
|
||||
}
|
||||
|
||||
#if 0
|
||||
|
||||
#if !BX_CRT_NONE
|
||||
# include <stdio.h> // vsnprintf
|
||||
#endif // !BX_CRT_NONE
|
||||
|
||||
int32_t vsnprintf(char* _out, int32_t _max, const char* _format, va_list _argList)
|
||||
{
|
||||
va_list argList;
|
||||
va_copy(argList, _argList);
|
||||
int32_t total = 0;
|
||||
#if BX_CRT_NONE
|
||||
total = vsnprintfRef(_out, _max, _format, argList);
|
||||
#elif BX_CRT_MSVC
|
||||
int32_t len = -1;
|
||||
if (NULL != _out)
|
||||
{
|
||||
va_list argListCopy;
|
||||
va_copy(argListCopy, _argList);
|
||||
len = ::vsnprintf_s(_out, _max, size_t(-1), _format, argListCopy);
|
||||
va_end(argListCopy);
|
||||
}
|
||||
total = -1 == len ? ::_vscprintf(_format, argList) : len;
|
||||
#else
|
||||
total = ::vsnprintf(_out, _max, _format, argList);
|
||||
#endif // BX_COMPILER_MSVC
|
||||
va_end(argList);
|
||||
return total;
|
||||
}
|
||||
|
||||
#endif // 0
|
||||
|
||||
int32_t snprintf(char* _out, int32_t _max, const char* _format, ...)
|
||||
{
|
||||
va_list argList;
|
||||
|
||||
Reference in New Issue
Block a user