JobManager::~JobManager ()
{
+ boost::this_thread::disable_interruption dis;
+
BOOST_FOREACH (boost::signals2::connection& i, _connections) {
i.disconnect ();
}
_empty_condition.notify_all ();
}
- if (_scheduler.joinable()) {
- try {
- _scheduler.join();
- } catch (...) {
-
- }
- }
+ try {
+ _scheduler.join();
+ } catch (...) {}
}
shared_ptr<Job>
BOOST_FOREACH (shared_ptr<Job> i, _jobs) {
shared_ptr<AnalyseAudioJob> a = dynamic_pointer_cast<AnalyseAudioJob> (i);
- if (a && a->path() == film->audio_analysis_path(playlist)) {
+ if (a && a->path() == film->audio_analysis_path(playlist) && !i->finished_cancelled()) {
i->when_finished (connection, ready);
return;
}