From ee5b82d873acc6fbbfab6081929418a28676bdf3 Mon Sep 17 00:00:00 2001 From: Marcus Holland-Moritz Date: Wed, 20 Nov 2024 18:07:57 +0100 Subject: [PATCH] fix: explicitly set UTF8 code page on windows --- src/util.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/util.cpp b/src/util.cpp index b0609c144..1547408e4 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -324,6 +324,9 @@ void setup_default_locale() { << "\n"; } } +#ifdef _WIN32 + SetConsoleOutputCP(CP_UTF8); +#endif } std::string error_cp_to_utf8(std::string_view error) {