This commit is contained in:
Akash Mozumdar 2018-09-21 22:20:53 -04:00
parent 4dc7b236c9
commit e5dcd33680

View File

@ -32,7 +32,7 @@ namespace Host
inline std::wstring ToWString(const char* text, UINT encoding)
{
std::wstring ret(strlen(text), 0);
ret.resize(MultiByteToWideChar(encoding, 0, text, -1, ret.data(), ret.size()));
ret.resize(MultiByteToWideChar(encoding, 0, text, -1, ret.data(), ret.capacity()));
return ret;
}