mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-30 12:49:40 +00:00
bus: Add guards against invalid arguments to set_flushing() and poll()
https://bugzilla.gnome.org/show_bug.cgi?id=746871
This commit is contained in:
parent
a041d8862d
commit
2064a07feb
1 changed files with 4 additions and 0 deletions
|
@ -448,6 +448,8 @@ gst_bus_set_flushing (GstBus * bus, gboolean flushing)
|
|||
GstMessage *message;
|
||||
GList *message_list = NULL;
|
||||
|
||||
g_return_if_fail (GST_IS_BUS (bus));
|
||||
|
||||
GST_OBJECT_LOCK (bus);
|
||||
|
||||
if (flushing) {
|
||||
|
@ -1122,6 +1124,8 @@ gst_bus_poll (GstBus * bus, GstMessageType events, GstClockTime timeout)
|
|||
GstMessage *ret;
|
||||
gulong id;
|
||||
|
||||
g_return_val_if_fail (GST_IS_BUS (bus), NULL);
|
||||
|
||||
poll_data = g_slice_new (GstBusPollData);
|
||||
poll_data->source_running = TRUE;
|
||||
poll_data->loop = g_main_loop_new (NULL, FALSE);
|
||||
|
|
Loading…
Reference in a new issue