Commit c618e994 authored by Hugh McMaster's avatar Hugh McMaster Committed by Alexandre Julliard

reg/tests: Pass MultiByteToWideChar() the buffer size in characters.

parent 84f5761a
......@@ -766,7 +766,7 @@ static BOOL test_import_wstr_(unsigned line, const char *file_contents, DWORD *r
memsize = len * sizeof(WCHAR);
wstr = HeapAlloc(GetProcessHeap(), 0, memsize);
if (!wstr) return FALSE;
MultiByteToWideChar(CP_UTF8, 0, file_contents, lenA, wstr, memsize);
MultiByteToWideChar(CP_UTF8, 0, file_contents, lenA, wstr, len);
regfile = CreateFileA("test.reg", GENERIC_WRITE, 0, NULL, CREATE_ALWAYS,
FILE_ATTRIBUTE_NORMAL, NULL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment