SmartAudio/package/avs/libsensory/files/wrapper/chk/mbstowcs_chk.c

8 lines
190 B
C
Raw Normal View History

2018-07-13 01:31:50 +00:00
#include <wchar.h>
#include "fortify.h"
size_t __mbstowcs_chk(wchar_t *restrict ws, const char *restrict s, size_t wn, size_t dn)
{
if(dn < wn) __chk_fail();
return mbstowcs(ws, s, wn);
}