We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
fsbridge::fopen()
1 parent dbe770d commit 53e4951Copy full SHA for 53e4951
src/util/fs.cpp
@@ -12,7 +12,6 @@
12
#include <sys/utsname.h>
13
#include <unistd.h>
14
#else
15
-#include <codecvt>
16
#include <limits>
17
#include <windows.h>
18
#endif
@@ -28,8 +27,7 @@ FILE *fopen(const fs::path& p, const char *mode)
28
27
#ifndef WIN32
29
return ::fopen(p.c_str(), mode);
30
31
- std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>,wchar_t> utf8_cvt;
32
- return ::_wfopen(p.wstring().c_str(), utf8_cvt.from_bytes(mode).c_str());
+ return ::fopen(p.utf8string().c_str(), mode);
33
34
}
35
0 commit comments