Remove unnecessary calls to c_str() for wxLogError() arguments

Just pass strings to wxLogError() directly.

No real changes.
This commit is contained in:
Vadim Zeitlin
2021-06-20 21:57:22 +02:00
parent 94576538d3
commit 862c051e9e

View File

@@ -305,7 +305,7 @@ bool wxRegExImpl::Compile(const wxString& expr, int flags)
if ( errorcode ) if ( errorcode )
{ {
wxLogError(_("Invalid regular expression '%s': %s"), wxLogError(_("Invalid regular expression '%s': %s"),
expr.c_str(), GetErrorMsg(errorcode, !conv).c_str()); expr, GetErrorMsg(errorcode, !conv));
m_isCompiled = false; m_isCompiled = false;
} }
@@ -426,7 +426,7 @@ bool wxRegExImpl::Matches(const wxRegChar *str,
default: default:
// an error occurred // an error occurred
wxLogError(_("Failed to find match for regular expression: %s"), wxLogError(_("Failed to find match for regular expression: %s"),
GetErrorMsg(rc, !str).c_str()); GetErrorMsg(rc, !str));
wxFALLTHROUGH; wxFALLTHROUGH;
case REG_NOMATCH: case REG_NOMATCH:
@@ -474,7 +474,7 @@ int wxRegExImpl::Replace(wxString *text,
if (!textstr) if (!textstr)
{ {
wxLogError(_("Failed to find match for regular expression: %s"), wxLogError(_("Failed to find match for regular expression: %s"),
GetErrorMsg(0, true).c_str()); GetErrorMsg(0, true));
return 0; return 0;
} }
size_t textlen = strlen(textstr); size_t textlen = strlen(textstr);