diff --git a/IO/src/FileStreamWin32.cpp b/IO/src/FileStreamWin32.cpp index 2fce0f5..5042eb6 100755 --- a/IO/src/FileStreamWin32.cpp +++ b/IO/src/FileStreamWin32.cpp @@ -61,6 +61,11 @@ #include #include +#ifdef _MSC_VER +#define snprintf(out, outSz, fmt, ...) _snprintf_s(out, outSz, _TRUNCATE, fmt, __VA_ARGS__) +#define strncpy(dst, src, dstSz) strncpy_s(dst, dstSz, src, _TRUNCATE) +#endif + void ErrorExit(LPCSTR lpszFunction) { // Retrieve the system error message for the last-error code