[Hotfix] fs::exists(fs::path{name}) does not work for Chinese characters in windows

This commit is contained in:
Akkadius 2024-02-10 03:57:50 -06:00
parent 91f5932c6d
commit 801025c166

View File

@ -47,7 +47,9 @@ namespace fs = std::filesystem;
*/
bool File::Exists(const std::string &name)
{
return fs::exists(fs::path{name});
// fs::exists(fs::path{name}) does not work for Chinese characters in windows
std::ifstream f(name);
return f.good();
}
/**