mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-05 06:58:56 +00:00
decodebin3: fix event leaks
Returning GST_PAD_PROBE_HANDLED means we are taking care of unreffing the probe info. https://bugzilla.gnome.org/show_bug.cgi?id=768811
This commit is contained in:
parent
51055f1924
commit
e2263673d1
2 changed files with 5 additions and 1 deletions
|
@ -1446,6 +1446,8 @@ multiqueue_src_probe (GstPad * pad, GstPadProbeInfo * info,
|
||||||
if (peer) {
|
if (peer) {
|
||||||
gst_pad_send_event (peer, ev);
|
gst_pad_send_event (peer, ev);
|
||||||
gst_object_unref (peer);
|
gst_object_unref (peer);
|
||||||
|
} else {
|
||||||
|
gst_event_unref (ev);
|
||||||
}
|
}
|
||||||
SELECTION_LOCK (dbin);
|
SELECTION_LOCK (dbin);
|
||||||
/* FIXME : Shouldn't we try to re-assign the output instead of just
|
/* FIXME : Shouldn't we try to re-assign the output instead of just
|
||||||
|
@ -2237,6 +2239,8 @@ ghost_pad_event_probe (GstPad * pad, GstPadProbeInfo * info,
|
||||||
if ((peer = gst_pad_get_peer (pad))) {
|
if ((peer = gst_pad_get_peer (pad))) {
|
||||||
gst_pad_send_event (peer, event);
|
gst_pad_send_event (peer, event);
|
||||||
gst_object_unref (peer);
|
gst_object_unref (peer);
|
||||||
|
} else {
|
||||||
|
gst_event_unref (event);
|
||||||
}
|
}
|
||||||
/* Finally handle the switch */
|
/* Finally handle the switch */
|
||||||
if (streams)
|
if (streams)
|
||||||
|
|
|
@ -3816,7 +3816,7 @@ source_pad_blocked_cb (GstPad * pad, GstPadProbeInfo * info, gpointer user_data)
|
||||||
* want to block the pad on it if we didn't get any buffers before
|
* want to block the pad on it if we didn't get any buffers before
|
||||||
* EOS and expose the pad then. */
|
* EOS and expose the pad then. */
|
||||||
peer = gst_pad_get_peer (pad);
|
peer = gst_pad_get_peer (pad);
|
||||||
gst_pad_send_event (peer, gst_event_ref (event));
|
gst_pad_send_event (peer, event);
|
||||||
gst_object_unref (peer);
|
gst_object_unref (peer);
|
||||||
GST_LOG_OBJECT (pad, "Manually pushed sticky event through");
|
GST_LOG_OBJECT (pad, "Manually pushed sticky event through");
|
||||||
ret = GST_PAD_PROBE_HANDLED;
|
ret = GST_PAD_PROBE_HANDLED;
|
||||||
|
|
Loading…
Reference in a new issue