summaryrefslogtreecommitdiff
path: root/src/plugins/qmlprofiler
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2016-12-29 14:30:25 +0100
committerUlf Hermann <ulf.hermann@qt.io>2017-02-01 12:56:40 +0000
commit9fc79c43d8abc342629616878abfb6dd6c53f342 (patch)
tree0299a386cc12514c831341dcf75c99d1ffb60e45 /src/plugins/qmlprofiler
parentfcdcc4c7f84a6d4fca6f5db056ee2dc281971e5a (diff)
downloadqt-creator-9fc79c43d8abc342629616878abfb6dd6c53f342.tar.gz
QmlProfiler: Optimize loop over event types
Change-Id: I656ff49a9e62f128c4eed84882245aa490e2960e Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/plugins/qmlprofiler')
-rw-r--r--src/plugins/qmlprofiler/qmlprofilertracefile.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/qmlprofiler/qmlprofilertracefile.cpp b/src/plugins/qmlprofiler/qmlprofilertracefile.cpp
index 3add12e7d9..5123902ef1 100644
--- a/src/plugins/qmlprofiler/qmlprofilertracefile.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilertracefile.cpp
@@ -621,7 +621,7 @@ void QmlProfilerFileWriter::saveQtd(QIODevice *device)
stream.writeAttribute(_("totalTime"), QString::number(m_measuredTime));
const QVector<QmlEventType> &eventTypes = m_model->eventTypes();
- for (int typeIndex = 0; typeIndex < eventTypes.size(); ++typeIndex) {
+ for (int typeIndex = 0, end = eventTypes.length(); typeIndex < end; ++typeIndex) {
if (isCanceled())
return;