[Bug 755123] tagdemux: protect internal state for concurrent access

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Sat Sep 19 13:40:51 PDT 2015


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

--- Comment #14 from GstBlub <gstblub at gmail.com> ---
The reason I added a "locked" parameter is that the function in some instances
unlocks the object without aquiring the lock again.  This avoids having to lock
it again and then as soon as the function returns unlocking it.

Yes, it's a little ugly but I don't know if another mutex would help
simplifying it much.  I am worried about all kinds of functions (like
gst_pad_*, some gst_element_*) ending up calling back into the code causing
mutexes that are already locked to be locked again.  Of course we could use a
recursive mutex, but that comes with overhead, too.

FYI, I still haven't run into any crashes in tagdemux anymore.

-- 
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