From 53e4951a5b5b9d166d278db4240513d09b447f58 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Fri, 16 May 2025 12:25:40 +0100 Subject: [PATCH] Switch to ANSI Windows API in `fsbridge::fopen()` function --- src/util/fs.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/util/fs.cpp b/src/util/fs.cpp index ec4d551e78..692f671842 100644 --- a/src/util/fs.cpp +++ b/src/util/fs.cpp @@ -12,7 +12,6 @@ #include #include #else -#include #include #include #endif @@ -28,8 +27,7 @@ FILE *fopen(const fs::path& p, const char *mode) #ifndef WIN32 return ::fopen(p.c_str(), mode); #else - std::wstring_convert,wchar_t> utf8_cvt; - return ::_wfopen(p.wstring().c_str(), utf8_cvt.from_bytes(mode).c_str()); + return ::fopen(p.utf8string().c_str(), mode); #endif }