mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
gst/gstbus.c: The lock order should be maincontext > OBJECT_LOCK so we need to release the object lock when waking up...
Original commit message from CVS: * gst/gstbus.c: (gst_bus_wakeup_main_context): The lock order should be maincontext > OBJECT_LOCK so we need to release the object lock when waking up the mainloop to avoid deadlocks.
This commit is contained in:
parent
23bdf5c9fe
commit
6766b6a4a2
2 changed files with 15 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
||||||
|
2009-01-05 Wim Taymans <wim.taymans@collabora.co.uk>
|
||||||
|
|
||||||
|
* gst/gstbus.c: (gst_bus_wakeup_main_context):
|
||||||
|
The lock order should be maincontext > OBJECT_LOCK so we need to release
|
||||||
|
the object lock when waking up the mainloop to avoid deadlocks.
|
||||||
|
|
||||||
2009-01-05 Wim Taymans <wim.taymans@collabora.co.uk>
|
2009-01-05 Wim Taymans <wim.taymans@collabora.co.uk>
|
||||||
|
|
||||||
* gst/gstbin.c: (gst_bin_set_index_func), (gst_bin_set_clock_func),
|
* gst/gstbin.c: (gst_bin_set_index_func), (gst_bin_set_clock_func),
|
||||||
|
|
10
gst/gstbus.c
10
gst/gstbus.c
|
@ -298,9 +298,17 @@ gst_bus_get_property (GObject * object, guint prop_id,
|
||||||
static void
|
static void
|
||||||
gst_bus_wakeup_main_context (GstBus * bus)
|
gst_bus_wakeup_main_context (GstBus * bus)
|
||||||
{
|
{
|
||||||
|
GMainContext *ctx;
|
||||||
|
|
||||||
GST_OBJECT_LOCK (bus);
|
GST_OBJECT_LOCK (bus);
|
||||||
g_main_context_wakeup (bus->priv->main_context);
|
if ((ctx = bus->priv->main_context))
|
||||||
|
g_main_context_ref (ctx);
|
||||||
GST_OBJECT_UNLOCK (bus);
|
GST_OBJECT_UNLOCK (bus);
|
||||||
|
|
||||||
|
g_main_context_wakeup (ctx);
|
||||||
|
|
||||||
|
if (ctx)
|
||||||
|
g_main_context_unref (ctx);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in a new issue