Fix clang warnings about copies in range-for constructs

Change-Id: If50553964483626e72a816b1d23fa81b45ed9ca7
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
Christian Kandeler
2020-06-15 13:40:39 +02:00
parent beee392dd8
commit 48be20cf48
11 changed files with 14 additions and 14 deletions

View File

@@ -353,7 +353,7 @@ void CtfTimelineModel::addCounterValue(const json &event, qint64 normalizedTime,
if (!event.contains("args")) return;
// CTF documentation says all keys of 'args' should be displayed in
// one stacked graph, but we will display them separately:
for (const auto it : event["args"].items()) {
for (const auto &it : event["args"].items()) {
std::string counterName = event.contains("id") ?
name + event.value("id", "") : name;
const std::string &key = it.key();