Use QString's multi-arg overload to save memory allocations. [-Wclazy-qstring-arg] Thanks Clazy!
This commit is contained in:
committed by
wmayer
parent
216106e407
commit
317bcd59c9
@@ -241,15 +241,15 @@ int main( int argc, char ** argv )
|
||||
msg = QObject::tr("While initializing %1 the following exception occurred: '%2'\n\n"
|
||||
"Python is searching for its files in the following directories:\n%3\n\n"
|
||||
"Python version information:\n%4\n")
|
||||
.arg(appName).arg(QString::fromUtf8(e.what()))
|
||||
.arg(appName, QString::fromUtf8(e.what()),
|
||||
#if PY_MAJOR_VERSION >= 3
|
||||
#if PY_MINOR_VERSION >= 5
|
||||
.arg(QString::fromUtf8(Py_EncodeLocale(Py_GetPath(),NULL))).arg(QString::fromLatin1(Py_GetVersion()));
|
||||
QString::fromUtf8(Py_EncodeLocale(Py_GetPath(),NULL)), QString::fromLatin1(Py_GetVersion()));
|
||||
#else
|
||||
.arg(QString::fromUtf8(_Py_wchar2char(Py_GetPath(),NULL))).arg(QString::fromLatin1(Py_GetVersion()));
|
||||
QString::fromUtf8(_Py_wchar2char(Py_GetPath(),NULL)), QString::fromLatin1(Py_GetVersion()));
|
||||
#endif
|
||||
#else
|
||||
.arg(QString::fromUtf8(Py_GetPath())).arg(QString::fromLatin1(Py_GetVersion()));
|
||||
QString::fromUtf8(Py_GetPath()), QString::fromLatin1(Py_GetVersion()));
|
||||
#endif
|
||||
const char* pythonhome = getenv("PYTHONHOME");
|
||||
if (pythonhome) {
|
||||
|
||||
Reference in New Issue
Block a user