Commit e363219c authored by salix5's avatar salix5

unicode script filename in windows

parent d66ac49f
......@@ -123,7 +123,7 @@ void Replay::EndRecord() {
is_recording = false;
}
void Replay::SaveReplay(const wchar_t* name) {
wchar_t fname[64];
wchar_t fname[256];
myswprintf(fname, L"./replay/%ls.yrp", name);
#ifdef WIN32
fp = _wfopen(fname, L"wb");
......
......@@ -31,11 +31,7 @@ int SingleMode::SinglePlayThread(void* param) {
wchar_t fname[256];
myswprintf(fname, L"./single/%ls", name);
char fname2[256];
#ifdef _WIN32
size_t slen = WideCharToMultiByte(CP_ACP, 0, fname, -1, fname2, 256, NULL, NULL);
#else
size_t slen = BufferIO::EncodeUTF8(fname, fname2);
#endif
mtrandom rnd;
time_t seed = time(0);
rnd.reset(seed);
......
Subproject commit 62ab0c81d4bd57521148e911776675f084faa785
Subproject commit dd955dbac2836581307777463d8fcc6f054b4384
Subproject commit 16ce4895cf02438eb598d351fff6ec3f1e94b0ea
Subproject commit 7d28acac8e17f3d63c115cccbe5b5dabb80e4e1f
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment