From dc99410902b9eade9e408389e49f09d5163b6caf Mon Sep 17 00:00:00 2001 From: Thorbjørn Lindeijer Date: Thu, 28 Mar 2024 08:18:44 -0700 Subject: Enable UTF-8 support on Windows This relies on Windows 10 version 1803 (10.0.17134.0), which is hopefully an acceptable minimum. It fixes handling of paths with special characters. --- src/main.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main.cpp b/src/main.cpp index 9b29eba4..7b9e921e 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -205,6 +205,9 @@ int main(int argc, char *argv[]) // Load mingw crash handler. Won't fail if dll is not present. LoadLibrary("exchndl.dll"); #endif +#ifdef _WIN32 + setlocale(LC_ALL, ".UTF8"); +#endif // Parse command line options Client::Options options; -- cgit v1.2.3-70-g09d2