mirror of
https://github.com/RPCS3/soundtouch.git
synced 2024-11-24 03:49:49 +00:00
Replaced proprietary strcpy_s with ansi-compatible strncpy
This commit is contained in:
parent
4c223f5a79
commit
8116c7bd42
@ -35,6 +35,7 @@
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <windows.h>
|
||||
#include <string.h>
|
||||
#include "SoundTouchDLL.h"
|
||||
#include "soundtouch.h"
|
||||
|
||||
@ -112,7 +113,8 @@ SOUNDTOUCHDLL_API const char *__stdcall soundtouch_getVersionString()
|
||||
/// environments that can't properly handle character string as return value
|
||||
SOUNDTOUCHDLL_API void __stdcall soundtouch_getVersionString2(char* versionString, int bufferSize)
|
||||
{
|
||||
strcpy_s(versionString, bufferSize, SoundTouch::getVersionString());
|
||||
strncpy(versionString, SoundTouch::getVersionString(), bufferSize - 1);
|
||||
versionString[bufferSize - 1] = 0;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user