From 8f20dd34903fa575e137eca430f105001672d186 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 14 Aug 2021 17:12:33 +0100 Subject: [PATCH] Remove obsolete AIX workaround from wxLocale code This code, added back in 420de418ea (workaround for buggy setlocale() under AIX (without this wxLocale didn't work at all), 2005-09-18), is probably irrelevant anyhow because AIX 5.2 must not be used any more, but also seems to have lost its purpose at some time during the intervening years, as we don't use "retloc" as argument to setlocale() anyhow, so it is doubly safe to simply remove it. --- src/common/intl.cpp | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/src/common/intl.cpp b/src/common/intl.cpp index c6c82186d2..cc8588ba31 100644 --- a/src/common/intl.cpp +++ b/src/common/intl.cpp @@ -552,20 +552,6 @@ bool wxLocale::Init(int lang, int flags) if ( !localeAlt.empty() ) retloc = wxSetlocaleTryAll(LC_ALL, localeAlt); } - -#ifdef __AIX__ - // at least in AIX 5.2 libc is buggy and the string returned from - // setlocale(LC_ALL) can't be passed back to it because it returns 6 - // strings (one for each locale category), i.e. for C locale we get back - // "C C C C C C" - // - // this contradicts IBM own docs but this is not of much help, so just work - // around it in the crudest possible manner - char* p = const_cast(wxStrchr(retloc, ' ')); - if ( p ) - *p = '\0'; -#endif // __AIX__ - #elif defined(__WIN32__) if ( lang == wxLANGUAGE_DEFAULT ) {