diff options
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/job.cc | 14 | ||||
| -rw-r--r-- | src/lib/playlist.cc | 2 | ||||
| -rw-r--r-- | src/lib/transcoder.cc | 16 |
3 files changed, 15 insertions, 17 deletions
diff --git a/src/lib/job.cc b/src/lib/job.cc index ff0332d6d..f830975af 100644 --- a/src/lib/job.cc +++ b/src/lib/job.cc @@ -68,11 +68,15 @@ Job::run_wrapper () set_state (FINISHED_ERROR); string m = String::compose (_("An error occurred whilst handling the file %1."), boost::filesystem::path (e.filename()).leaf()); - - boost::filesystem::space_info const s = boost::filesystem::space (e.filename()); - if (s.available < pow (1024, 3)) { - m += N_("\n\n"); - m += _("The drive that the film is stored on is low in disc space. Free some more space and try again."); + + try { + boost::filesystem::space_info const s = boost::filesystem::space (e.filename()); + if (s.available < pow (1024, 3)) { + m += N_("\n\n"); + m += _("The drive that the film is stored on is low in disc space. Free some more space and try again."); + } + } catch (...) { + } set_error (e.what(), m); diff --git a/src/lib/playlist.cc b/src/lib/playlist.cc index 58086d02b..7fe4fb2a5 100644 --- a/src/lib/playlist.cc +++ b/src/lib/playlist.cc @@ -288,7 +288,7 @@ Playlist::video_digest () const for (list<shared_ptr<const VideoContent> >::const_iterator i = _video.begin(); i != _video.end(); ++i) { t += (*i)->digest (); shared_ptr<const FFmpegContent> fc = dynamic_pointer_cast<const FFmpegContent> (*i); - if (fc) { + if (fc && fc->subtitle_stream()) { t += fc->subtitle_stream()->id; } } diff --git a/src/lib/transcoder.cc b/src/lib/transcoder.cc index e0e127d33..2a8ce5044 100644 --- a/src/lib/transcoder.cc +++ b/src/lib/transcoder.cc @@ -79,19 +79,13 @@ void Transcoder::go () { _encoder->process_begin (); - try { - while (1) { - if (_player->pass ()) { - break; - } - _player->set_progress (_job); + while (1) { + if (_player->pass ()) { + break; } - - } catch (...) { - _encoder->process_end (); - throw; + _player->set_progress (_job); } - + if (_delay_line) { _delay_line->process_end (); } |
