Merge pull request #199 from dgarske/ChangeToWolfRootWarnFix

Fixes "warning: Size argument is greater than the free space in the d…
This commit is contained in:
toddouska 2015-11-23 14:43:45 -08:00
commit 6c1fd13184

View File

@ -1185,10 +1185,10 @@ static INLINE int OpenNitroxDevice(int dma_mode,int dev_id)
return depth;
}
#ifdef USE_WINDOWS_API
XSTRNCAT(path, "..\\", MAX_PATH);
XSTRNCAT(path, "..\\", MAX_PATH - XSTRLEN(path));
SetCurrentDirectoryA(path);
#else
XSTRNCAT(path, "../", MAX_PATH);
XSTRNCAT(path, "../", MAX_PATH - XSTRLEN(path));
if (chdir(path) < 0) {
printf("chdir to %s failed\n", path);
break;