Fix UTF-8 filepath on LLVM MinGW

This commit is contained in:
operatios
2022-09-24 22:37:14 +03:00
parent cad515fbc3
commit 7c3bb11092

View File

@@ -2597,7 +2597,7 @@ bool FileExists(const std::string &abs_filename, void *) {
}
#else
#ifdef _WIN32
#if defined(_MSC_VER) || defined(__GLIBCXX__)
#if defined(_MSC_VER) || defined(__GLIBCXX__) || defined(_LIBCPP_VERSION)
FILE *fp = nullptr;
errno_t err = _wfopen_s(&fp, UTF8ToWchar(abs_filename).c_str(), L"rb");
if (err != 0) {