mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-22 14:06:23 +00:00
gst/gstbin.c: Make default message forwarding from child->bus to bin->bus threadsafe and make it not emit warnings if...
Original commit message from CVS: * gst/gstbin.c: (bin_bus_handler): Make default message forwarding from child->bus to bin->bus threadsafe and make it not emit warnings if the parent has no bus.
This commit is contained in:
parent
c27821d70c
commit
0454767817
2 changed files with 22 additions and 3 deletions
|
@ -1,3 +1,9 @@
|
|||
2005-08-08 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
|
||||
|
||||
* gst/gstbin.c: (bin_bus_handler):
|
||||
Make default message forwarding from child->bus to bin->bus
|
||||
threadsafe and make it not emit warnings if the parent has no bus.
|
||||
|
||||
2005-08-08 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
|
||||
|
||||
* gst/gstelement.c: (activate_pads):
|
||||
|
|
15
gst/gstbin.c
15
gst/gstbin.c
|
@ -1468,12 +1468,25 @@ bin_bus_handler (GstBus * bus, GstMessage * message, GstBin * bin)
|
|||
gst_message_unref (message);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
default:{
|
||||
GstBus *bus;
|
||||
|
||||
/* Send all other messages upward */
|
||||
GST_LOCK (bin);
|
||||
if (!(bus = GST_ELEMENT (bin)->bus)) {
|
||||
GST_DEBUG_OBJECT (bin, "dropping message because no parent bus");
|
||||
GST_UNLOCK (bin);
|
||||
} else {
|
||||
gst_object_ref (bus);
|
||||
GST_UNLOCK (bin);
|
||||
|
||||
GST_DEBUG_OBJECT (bin, "posting message upward");
|
||||
gst_bus_post (GST_ELEMENT (bin)->bus, message);
|
||||
gst_object_unref (bus);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return GST_BUS_DROP;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue