From 0e78dd5eac88f122ae9e60cf3ac0c1f151f8c023 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Sun, 2 Oct 2016 18:11:44 +0200 Subject: [PATCH] GUI: refactoring, replace .c_str() --- gui/erroritem.h | 2 +- gui/threadresult.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gui/erroritem.h b/gui/erroritem.h index 3c5f601ee..065bff932 100644 --- a/gui/erroritem.h +++ b/gui/erroritem.h @@ -38,7 +38,7 @@ class ErrorLine; class GuiSeverity { public: static QString toString(Severity::SeverityType severity) { - return QString(Severity::toString(severity).c_str()); + return QString::fromStdString(Severity::toString(severity)); } static Severity::SeverityType fromString(const QString &severity) { diff --git a/gui/threadresult.cpp b/gui/threadresult.cpp index bc9a0449f..de3b5b05d 100644 --- a/gui/threadresult.cpp +++ b/gui/threadresult.cpp @@ -67,7 +67,7 @@ void ThreadResult::reportErr(const ErrorLogger::ErrorMessage &msg) for (std::list::const_iterator tok = msg._callStack.begin(); tok != msg._callStack.end(); ++tok) { - files << QString((*tok).getfile(false).c_str()); + files << QString::fromStdString((*tok).getfile(false)); lines << (*tok).line; }