Convert Sys_Mkdir from DOS to WinAPI.

With this we're able to create directorys with Unicode characters
anywhere in the path.
This commit is contained in:
Yamagi Burmeister 2018-02-04 13:04:31 +01:00
parent e8c3686e4c
commit 4ca38f92fa

View file

@ -461,8 +461,10 @@ Sys_GetGameAPI(void *parms)
void
Sys_Mkdir(char *path)
{
// TODO: Use CreateDirectory() instead
_mkdir(path);
WCHAR wpath[MAX_OSPATH] = {0};
MultiByteToWideChar(CP_UTF8, 0, path, -1, wpath, MAX_OSPATH);
CreateDirectoryW(wpath, NULL);
}
char *