[Bug 755169] dashdemux: can we have multiple seek events at the same time?

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Tue Sep 22 10:38:28 PDT 2015


https://bugzilla.gnome.org/show_bug.cgi?id=755169

--- Comment #24 from Florin Apostol <florin.apostol at oregan.net> ---
My solution is the following:
1. gst_adaptive_demux_src_event grabs the api_lock so that it is the only one
doing cleanup
2. for each stream to stop, gst_adaptive_demux_stop_tasks grabs a new lock
stream->lock and sets a new flag stream->cancelled to tell the download loop to
abort

3. very important: download_loop grabs the stream->lock every time it wants to
read or write the stream object. Which should be almost all its life, except
when blocking in conditions
4. very important: every time download_loop grabs the stream->lock , it checks
for the stream->cancelled flag and if set, it exits. 

The 3 and 4 steps allow us to safely ask the download_loop to exit and wait for
it to do so.

We still need to see how to protect write accesses done by download_loop on the
demux object (things like demux->priv->old_streams = NULL; or
gst_adaptive_demux_advance_period (demux); )

My feeling is that manifest lock or GST_OBJECT_LOCK (demux) should guard all
accesses to demux object and stream->lock should guard all accesses to stream
object.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list