aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qmlprofiler/qmleventtype.cpp
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2018-05-07 10:50:58 +0200
committerUlf Hermann <ulf.hermann@qt.io>2018-07-16 10:03:59 +0000
commit37bcbf75751cf562bc431ae01f85c56193b85a04 (patch)
tree3cd87de9a13cc8464cbbeb63c9350fd6a78b5513 /src/plugins/qmlprofiler/qmleventtype.cpp
parentc73c86e1a3346c86bb868396d7d5be905a313e0c (diff)
Tracing: Make sure we don't cast between different kinds of events
Add a classId to TraceEvent and TraceEventType and add is() and as() methods that check for it. Change-Id: I76fe1df624516b36db90d57d4788b17e0b690726 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Diffstat (limited to 'src/plugins/qmlprofiler/qmleventtype.cpp')
-rw-r--r--src/plugins/qmlprofiler/qmleventtype.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/qmlprofiler/qmleventtype.cpp b/src/plugins/qmlprofiler/qmleventtype.cpp
index 9cb99c0081e..88a3d6dd47c 100644
--- a/src/plugins/qmlprofiler/qmleventtype.cpp
+++ b/src/plugins/qmlprofiler/qmleventtype.cpp
@@ -79,7 +79,7 @@ QDataStream &operator<<(QDataStream &stream, const QmlEventType &type)
QmlEventType::QmlEventType(Message message, RangeType rangeType, int detailType,
const QmlEventLocation &location, const QString &data,
const QString displayName) :
- TraceEventType(qmlFeatureFromType(message, rangeType, detailType)),
+ TraceEventType(staticClassId, qmlFeatureFromType(message, rangeType, detailType)),
m_data(data), m_location(location), m_message(message),
m_rangeType(rangeType), m_detailType(detailType)
{