swaroop: fix incorrect start times with encrypted MP4 content. attic/swaroop-v2.15.x
authorCarl Hetherington <cth@carlh.net>
Mon, 13 May 2019 23:14:38 +0000 (00:14 +0100)
committerCarl Hetherington <cth@carlh.net>
Mon, 13 May 2019 23:14:38 +0000 (00:14 +0100)
src/lib/ffmpeg_content.cc
src/wx/swaroop_controls.cc

index e291b8e..97e12cc 100644 (file)
@@ -259,7 +259,9 @@ FFmpegContent::examine (shared_ptr<const Film> film, shared_ptr<Job> job)
        ChangeSignaller<Content> cc1 (this, FFmpegContentProperty::SUBTITLE_STREAMS);
        ChangeSignaller<Content> cc2 (this, FFmpegContentProperty::SUBTITLE_STREAM);
 
-       job->set_progress_unknown ();
+       if (job) {
+               job->set_progress_unknown ();
+       }
 
        Content::examine (film, job);
 
index c76ad59..d8019a4 100644 (file)
@@ -471,6 +471,7 @@ SwaroopControls::select_playlist (int selected, int position)
                        if (kdm) {
                                try {
                                        ffmpeg->add_kdm (*kdm);
+                                       ffmpeg->examine (_film, shared_ptr<Job>());
                                } catch (KDMError& e) {
                                        error_dialog (this, "Could not load KDM.");
                                }