diff options
| author | Carl Hetherington <cth@carlh.net> | 2019-05-30 20:08:39 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2019-05-30 20:08:39 +0100 |
| commit | 9b98a07cb61fd66fd73f9f58468100ec9b7eddd3 (patch) | |
| tree | bb04cfeae771bf571dc919bca0fdf8d10fb0d560 /src/lib/job.cc | |
| parent | fd7cf313b4d809bde22b5189e1ab22c5edbd8f8f (diff) | |
Destory TranscodeJob earlier, hopefully to fix #1570.
Diffstat (limited to 'src/lib/job.cc')
| -rw-r--r-- | src/lib/job.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/lib/job.cc b/src/lib/job.cc index 1416ddfc2..43b5fb7e1 100644 --- a/src/lib/job.cc +++ b/src/lib/job.cc @@ -63,6 +63,12 @@ Job::Job (shared_ptr<const Film> film) Job::~Job () { + stop_thread (); +} + +void +Job::stop_thread () +{ if (_thread) { _thread->interrupt (); /* We can't use DCPOMATIC_ASSERT here as it may throw an exception */ @@ -76,6 +82,7 @@ Job::~Job () } delete _thread; + _thread = 0; } /** Start the job in a separate thread, returning immediately */ |
