Fix build break on VS2019 due to implicit wchar_t->char conversion

Converting std::wstring to std::string by constructing the latter with
wchar_t iterators result in implicit conversion of wchar_t to char which
trips Visual Studio 2019 compiler into throwing a warning of potential
data loss during conversion. Use conv() helper function to do the
conversion and please the compiler at the same time.
This commit is contained in:
Alex Vakulenko
2020-01-17 08:10:47 -05:00
committed by Baldur Karlsson
parent 526240f2d5
commit 6cd2d18d9e
+1 -2
View File
@@ -541,8 +541,7 @@ struct CrashHandlerCommand : public Command
}
else
{
report += " \"" + std::string(name.begin(), name.end()) + "\": \"" +
std::string(val.begin(), val.end()) + "\",\n";
report += " \"" + conv(name) + "\": \"" + conv(val) + "\",\n";
}
}