Small fix in load_string() function.

This commit is contained in:
LoRd_MuldeR 2020-09-28 21:21:57 +02:00
parent 5be76ac282
commit bdcd0abcc5

View File

@ -286,7 +286,7 @@ static wchar_t *load_string(const HINSTANCE hinstance, const UINT id)
{
if (buffer = (wchar_t*) malloc(sizeof(wchar_t) * (str_len + 1U)))
{
if(LoadStringW(hinstance, id, buffer, str_len) > 0)
if(LoadStringW(hinstance, id, buffer, str_len + 1U) > 0)
{
return wcstrim(buffer);
}