X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fjob.cc;h=7aaac748c115a1d9e65144027e7eacf96f1d6640;hb=d2ca18d5b2a3351745cc8be2840308808e5a2d36;hp=439000e5876dcc61b061c8ddbfdf6645be026905;hpb=511f4bbb6dd088cc32163edfe5004761a33a8311;p=dcpomatic.git diff --git a/src/lib/job.cc b/src/lib/job.cc index 439000e58..7aaac748c 100644 --- a/src/lib/job.cc +++ b/src/lib/job.cc @@ -59,6 +59,7 @@ Job::~Job () { if (_thread) { _thread->interrupt (); + DCPOMATIC_ASSERT (_thread->joinable ()); _thread->join (); } @@ -416,7 +417,10 @@ Job::cancel () } _thread->interrupt (); + DCPOMATIC_ASSERT (_thread->joinable ()); _thread->join (); + delete _thread; + _thread = 0; } void