mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
libs/gst/base/gstbasesink.c: Only send upstream events upstream. Fixes #498746.
Original commit message from CVS: * libs/gst/base/gstbasesink.c: (gst_base_sink_send_event): Only send upstream events upstream. Fixes #498746.
This commit is contained in:
parent
54ff34dc2d
commit
b4c503929a
2 changed files with 12 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
2007-11-21 Wim Taymans <wim.taymans@gmail.com>
|
||||
|
||||
* libs/gst/base/gstbasesink.c: (gst_base_sink_send_event):
|
||||
Only send upstream events upstream. Fixes #498746.
|
||||
|
||||
2007-11-21 Wim Taymans <wim.taymans@gmail.com>
|
||||
|
||||
Patch by: Laurent Glayal <spglegle at yahoo dot fr>
|
||||
|
|
|
@ -2927,7 +2927,10 @@ gst_base_sink_send_event (GstElement * element, GstEvent * event)
|
|||
{
|
||||
GstPad *pad;
|
||||
GstBaseSink *basesink = GST_BASE_SINK (element);
|
||||
gboolean forward = TRUE, result = TRUE;
|
||||
gboolean forward, result = TRUE;
|
||||
|
||||
/* only push UPSTREAM events upstream */
|
||||
forward = GST_EVENT_IS_UPSTREAM (event);
|
||||
|
||||
switch (GST_EVENT_TYPE (event)) {
|
||||
case GST_EVENT_LATENCY:
|
||||
|
@ -2944,7 +2947,6 @@ gst_base_sink_send_event (GstElement * element, GstEvent * event)
|
|||
|
||||
/* don't forward, yet */
|
||||
forward = FALSE;
|
||||
gst_event_unref (event);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
@ -2959,6 +2961,9 @@ gst_base_sink_send_event (GstElement * element, GstEvent * event)
|
|||
result = gst_pad_push_event (pad, event);
|
||||
|
||||
gst_object_unref (pad);
|
||||
} else {
|
||||
/* not forwarded, unref the event */
|
||||
gst_event_unref (event);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue