From caf67bef2611a911307267b20dbf3be89ffff71f Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Fri, 6 Mar 2020 22:36:16 +0100 Subject: Stop threads at the start of their object's destruction in all Job cases. --- src/lib/job.cc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/lib/job.cc') diff --git a/src/lib/job.cc b/src/lib/job.cc index 04aa227b7..a83249e79 100644 --- a/src/lib/job.cc +++ b/src/lib/job.cc @@ -62,7 +62,10 @@ Job::Job (shared_ptr film) Job::~Job () { - stop_thread (); +#ifdef DCPOMATIC_DEBUG + /* Any subclass should have called stop_thread in its destructor */ + assert (!_thread.joinable()); +#endif } void -- cgit v1.2.3