From a37b12c8bc31f7b685c393ce0e6f389973d58725 Mon Sep 17 00:00:00 2001 From: Mathew Sutcliffe Date: Tue, 4 Jul 2017 23:08:21 +0100 Subject: [PATCH] T102 Fixed mistake that caused CWorkerPointer to delete the worker immediately as soon as it starts. --- src/blackmisc/worker.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/blackmisc/worker.h b/src/blackmisc/worker.h index 2bde3c043..276b15f86 100644 --- a/src/blackmisc/worker.h +++ b/src/blackmisc/worker.h @@ -329,7 +329,7 @@ namespace BlackMisc { if (!ptr || static_cast(ptr)->hasStarted()) { return; } m_strong.reset(ptr); - QObject::connect(ptr, &CWorkerBase::aboutToStart, [this] { m_strong.reset(); }); + QObject::connect(ptr, &CWorkerBase::aboutToStart, [this] { m_strong.release(); }); } //! Construct a null pointer.