From 1003cf3e9269078aa2b7ec0f3d08d6397b5ec262 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 14 Jul 2017 19:00:12 +0200 Subject: [PATCH] Remove unnecessary c_str() calls in wxLocale code Pass wxString directly to wxLogWarning(), there is no need for c_str() since wx 3.0 any more. --- src/common/intl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/intl.cpp b/src/common/intl.cpp index 6da4e18a77..c819090e1f 100644 --- a/src/common/intl.cpp +++ b/src/common/intl.cpp @@ -497,7 +497,7 @@ bool wxLocale::Init(int language, int flags) const char *retloc = "C"; if ( info->WinLang == 0 ) { - wxLogWarning(wxS("Locale '%s' not supported by OS."), name.c_str()); + wxLogWarning(wxS("Locale '%s' not supported by OS."), name); // retloc already set to "C" } else // language supported by Windows @@ -567,7 +567,7 @@ bool wxLocale::Init(int language, int flags) #ifndef WX_NO_LOCALE_SUPPORT if ( !ret ) { - wxLogWarning(_("Cannot set locale to language \"%s\"."), name.c_str()); + wxLogWarning(_("Cannot set locale to language \"%s\"."), name); // As we failed to change locale, there is no need to restore the // previous one: it's still valid.