#if LINUX_SYSTEM
int chVsprintf(LPSTR buffer, int nCount, LPCSTR format, va_list argptr)
{
return vsnprintf(buffer, nCount, format, argptr);
}
int chVsprintf(LPWSTR buffer, int nCount, LPCWSTR format, va_list argptr)
{
return vswprintf((LPWSTR)buffer, nCount, (LPWSTR)format, argptr);
}
#else
int chVsprintf(LPSTR buffer, int nCount, LPCSTR format, va_list argptr)
{
int nWrite = vsprintf(buffer, format, argptr);
chASSERT(nWrite < nCount);
return nWrite;
}
int chVsprintf(LPWSTR buffer, int nCount, LPCWSTR format, va_list argptr)
{
int nWrite = vswprintf(buffer, format, argptr);
chASSERT(nWrite < nCount);
return nWrite;
}
#endif

posted on 2016-10-18 19:39  叶城宇  阅读(215)  评论(0编辑  收藏  举报