mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-02 12:32:29 +00:00
typefind: fix leak in gst_type_find_element_src_event()
gst_type_find_element_src_event() is supposed to consume @event but wasn't doing so when it was handling the event itself. https://bugzilla.gnome.org/show_bug.cgi?id=747775 Signed-off-by: Guillaume Desmottes <guillaume.desmottes@collabora.co.uk>
This commit is contained in:
parent
e08c03ed07
commit
15fd78f0b6
1 changed files with 4 additions and 1 deletions
|
@ -500,6 +500,7 @@ gst_type_find_element_src_event (GstPad * pad, GstObject * parent,
|
|||
GstEvent * event)
|
||||
{
|
||||
GstTypeFindElement *typefind = GST_TYPE_FIND_ELEMENT (parent);
|
||||
gboolean result;
|
||||
|
||||
if (typefind->mode != MODE_NORMAL) {
|
||||
/* need to do more? */
|
||||
|
@ -510,7 +511,9 @@ gst_type_find_element_src_event (GstPad * pad, GstObject * parent,
|
|||
/* Only handle seeks here if driving the pipeline */
|
||||
if (typefind->segment.format != GST_FORMAT_UNDEFINED &&
|
||||
GST_EVENT_TYPE (event) == GST_EVENT_SEEK) {
|
||||
return gst_type_find_element_seek (typefind, event);
|
||||
result = gst_type_find_element_seek (typefind, event);
|
||||
gst_mini_object_unref (GST_MINI_OBJECT_CAST (event));
|
||||
return result;
|
||||
} else {
|
||||
return gst_pad_push_event (typefind->sink, event);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue