wscript: Use OEM code page for output.
Signed-off-by: Eric Pouech <eric.pouech@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
98838aaf97
commit
c277ef66fc
|
@ -80,12 +80,12 @@ static void print_string(const WCHAR *string)
|
|||
return;
|
||||
}
|
||||
|
||||
lena = WideCharToMultiByte(GetConsoleOutputCP(), 0, string, len, NULL, 0, NULL, NULL);
|
||||
lena = WideCharToMultiByte(GetOEMCP(), 0, string, len, NULL, 0, NULL, NULL);
|
||||
buf = heap_alloc(len);
|
||||
if(!buf)
|
||||
return;
|
||||
|
||||
WideCharToMultiByte(GetConsoleOutputCP(), 0, string, len, buf, lena, NULL, NULL);
|
||||
WideCharToMultiByte(GetOEMCP(), 0, string, len, buf, lena, NULL, NULL);
|
||||
WriteFile(GetStdHandle(STD_OUTPUT_HANDLE), buf, lena, &count, FALSE);
|
||||
heap_free(buf);
|
||||
WriteFile(GetStdHandle(STD_OUTPUT_HANDLE), "\r\n", 2, &count, FALSE);
|
||||
|
|
Loading…
Reference in New Issue