From 5b2ac16011f0fbd6b5809b9b8f7b8b440f2679c7 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Mon, 20 Aug 2018 11:58:18 +0200 Subject: [PATCH] QmlProfiler: Don't stop the RunControl from RunWorker dtor The QmlProfilerRunner is owned by its RunControl. It will only be destroyed from the RunControl's dtor and therefore we don't need to stop the RunControl at that point. Furthermore, accessing the RunControl there is dangerous because it is partially destroyed already. Change-Id: I006e053bb9cd0da23cedb8fedfc46e049b72517d Reviewed-by: hjk --- src/plugins/qmlprofiler/qmlprofilerruncontrol.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/plugins/qmlprofiler/qmlprofilerruncontrol.cpp b/src/plugins/qmlprofiler/qmlprofilerruncontrol.cpp index d2ee9434d18..8d10907f9eb 100644 --- a/src/plugins/qmlprofiler/qmlprofilerruncontrol.cpp +++ b/src/plugins/qmlprofiler/qmlprofilerruncontrol.cpp @@ -83,8 +83,6 @@ QmlProfilerRunner::QmlProfilerRunner(RunControl *runControl) QmlProfilerRunner::~QmlProfilerRunner() { - if (runControl()->isRunning() && d->m_profilerState) - runControl()->initiateStop(); delete d; }