From 0d4199656256be281a0218982e437867bda4f8a9 Mon Sep 17 00:00:00 2001 From: Muhammad Rifqi Priyo Susanto Date: Wed, 10 Jan 2024 07:00:00 +0700 Subject: [PATCH] MSVC: Fix locale workaround code --- src/gettext.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/gettext.cpp b/src/gettext.cpp index 1ddcd5ff6..49eb0981a 100644 --- a/src/gettext.cpp +++ b/src/gettext.cpp @@ -119,7 +119,7 @@ static const char* MSVC_LocaleLookup(const char* raw_shortname) return ""; } -static void MSVC_LocaleWorkaround() +static void MSVC_LocaleWorkaround(int argc, char* argv[]) { errorstream << "MSVC localization workaround active. " "Restarting " PROJECT_NAME_C " in a new environment!" << std::endl; @@ -165,7 +165,6 @@ static void MSVC_LocaleWorkaround() errorstream << "*******************************************************" << std::endl; } } -} #endif @@ -195,7 +194,7 @@ void init_gettext(const char *path, const std::string &configured_language, #ifndef SERVER // Hack to force gettext to see the right environment if (current_language != configured_language) - MSVC_LocaleWorkaround(); + MSVC_LocaleWorkaround(argc, argv); #else errorstream << "*******************************************************" << std::endl; errorstream << "Can't apply locale workaround for server!" << std::endl;