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 e291b8e7cb151b839969f61a1daa18468e42fa49..97e12cc86e69b653239ba6262dbd0ddddee5b006 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 c76ad590a21fb4c6abbc09f7c34e854cae55efac..d8019a41e7b840b4dc82a4bbee143ba167f59b48 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.");
                                }