1
0
mirror of synced 2025-04-19 00:24:02 +03:00
This commit is contained in:
yhirose 2024-11-27 12:18:35 -05:00 committed by GitHub
parent da2f9e476e
commit fe07660f40
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2271,7 +2271,7 @@ inline std::wstring u8string_to_wstring(const char *s) {
wlen = ::MultiByteToWideChar( wlen = ::MultiByteToWideChar(
CP_UTF8, 0, s, len, CP_UTF8, 0, s, len,
const_cast<LPWSTR>(reinterpret_cast<LPCWSTR>(ws.data())), wlen); const_cast<LPWSTR>(reinterpret_cast<LPCWSTR>(ws.data())), wlen);
if (wlen != ws.size()) { ws.clear(); } if (wlen != static_cast<int>(ws.size())) { ws.clear(); }
} }
return ws; return ws;
} }