diff --git a/dlls/shlwapi/wsprintf.c b/dlls/shlwapi/wsprintf.c index 10933932699..56eea41410d 100644 --- a/dlls/shlwapi/wsprintf.c +++ b/dlls/shlwapi/wsprintf.c @@ -488,7 +488,7 @@ INT WINAPI wvnsprintfW( LPWSTR buffer, INT maxlen, LPCWSTR spec, __ms_va_list ar case WPR_STRING: { LPCSTR ptr = argData.lpcstr_view; - for (i = 0; i < len; i++) *p++ = (WCHAR)*ptr++; + for (i = 0; i < len; i++) *p++ = (BYTE)*ptr++; } break; case WPR_WSTRING: @@ -514,7 +514,7 @@ INT WINAPI wvnsprintfW( LPWSTR buffer, INT maxlen, LPCWSTR spec, __ms_va_list ar /* fall through */ case WPR_UNSIGNED: for (i = len; i < format.precision; i++, maxlen--) *p++ = '0'; - for (i = sign; i < len; i++) *p++ = (WCHAR)number[i]; + for (i = sign; i < len; i++) *p++ = (BYTE)number[i]; break; case WPR_UNKNOWN: continue;