From 35fa7aed1db1157a7189ff271ebd241ebe04d2cc Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Tue, 15 Sep 2015 15:13:18 +0200 Subject: qmlprofiler: Clear trace client when trace is finished If the application was killed with -9 or similar there may be some open ranges left. We don't want them to influence the next session. Change-Id: I284086ff96d81a829f02e160ef8b82417fd51466 Reviewed-by: Simon Hausmann --- tools/qmlprofiler/qmlprofilerapplication.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/qmlprofiler/qmlprofilerapplication.cpp b/tools/qmlprofiler/qmlprofilerapplication.cpp index 010e82ce5a..11718d60ad 100644 --- a/tools/qmlprofiler/qmlprofilerapplication.cpp +++ b/tools/qmlprofiler/qmlprofilerapplication.cpp @@ -553,6 +553,8 @@ void QmlProfilerApplication::processFinished() } if (!m_interactive) exit(exitCode); + else + m_qmlProfilerClient.clearData(); } void QmlProfilerApplication::traceClientEnabledChanged(bool enabled) @@ -577,6 +579,8 @@ void QmlProfilerApplication::traceFinished() } else { prompt(tr("Application stopped recording."), false); } + + m_qmlProfilerClient.clearData(); } void QmlProfilerApplication::prompt(const QString &line, bool ready) -- cgit v1.2.3