After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 649878 - [multiqueue] regression: gst_single_queue_new not MT-safe
[multiqueue] regression: gst_single_queue_new not MT-safe
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other Linux
: Normal blocker
: 0.10.34
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-05-10 09:19 UTC by Mark Nauwelaerts
Modified: 2011-05-10 17:08 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
multiqueue: ensure MT-safety when adding a pad (1.25 KB, patch)
2011-05-10 09:19 UTC, Mark Nauwelaerts
committed Details | Review

Description Mark Nauwelaerts 2011-05-10 09:19:49 UTC
Created attachment 187566 [details] [review]
multiqueue: ensure MT-safety when adding a pad

gst_single_queue_new creates a single queue and adds this to the multiqueue, but it seems that GST_MULTI_QUEUE_MUTEX_UNLOCK is performed too soon.  Specifically, the lock is dropped before various fields of the single queue are setup, most notably the actual ->queue DataQueue, although the single queue is then already added to the list of multiqueue's queues.  Particularly the latter field may get accessed in some underrun/overrun callback iterating over all GstSingleQueue (leading to a NULL data queue).
Comment 1 Tim-Philipp Müller 2011-05-10 17:08:36 UTC
commit 24888ecc704599f4d0f6e632869b73214482d599
Author: Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
Date:   Tue May 10 11:11:15 2011 +0200

    multiqueue: ensure thread safety when adding a pad
    
    This seems to be a regression, and was causing crashes.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=649878