GNOME Bugzilla – Bug 782960
basesink: pipeline deadlocks when changing from PLAYING to PAUSED after processing a segment seek
Last modified: 2018-11-03 12:41:18 UTC
When using segment seeks to play sections of a stream and we try to pause the pipeline after the segment-done event had reached the sink, the change state never finishes and it's stuck waiting for a preroll buffer.
Created attachment 352366 [details] [review] Patch that adds a unit test to reproduce the problem
Created attachment 352367 [details] [review] Proposed fix This patch deals with the segment-done in basesink and make it participate on the needs_preroll check.
The patch makes sense to me, I notice that after syncing the event in the EOS case, we also set sink->eos, which ends up getting used for two purposes: * reporting eos after step done, I don't think this concerns us here * some logic in get_position, which I think would be applicable here This is not directly related to the issue, but as you're basically adding support for segment seeks in basesink here, might be worth it to look into that as well. Otherwise lgtm, please tell me if you can have a quick look at the point above :)
Do we need additional logic in gst_base_sink_get_sync_times() for the SEGMENT_DONE event as well then, similar to GST_EVENT_EOS?
In any case, it seems fine to me, so let's get it in and see what happens?
Josep?
I don't know when I'll be able to dig on this again. So feel free to push it if you'll think it is correct or keep it latent in bugzilla if there are doubts.
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gstreamer/issues/237.