Eric Pouech : wscript: Use OEM code page for output.

Alexandre Julliard julliard at winehq.org
Mon May 2 16:02:10 CDT 2022


Module: wine
Branch: master
Commit: c277ef66fc1d4c5cbebd07d389f4c789b113f3b8
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=c277ef66fc1d4c5cbebd07d389f4c789b113f3b8

Author: Eric Pouech <eric.pouech at gmail.com>
Date:   Thu Apr 28 11:22:40 2022 +0200

wscript: Use OEM code page for output.

Signed-off-by: Eric Pouech <eric.pouech at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 programs/wscript/host.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/programs/wscript/host.c b/programs/wscript/host.c
index bd16b7b4cbe..463f5ee7aa6 100644
--- a/programs/wscript/host.c
+++ b/programs/wscript/host.c
@@ -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);




More information about the wine-cvs mailing list