From e8a97877b44bba7b7c8e8d0222ddcf8ad0a91615 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Thu, 11 Jun 2015 15:22:04 +0200 Subject: [PATCH] gl: Use gst_object_ref_sink() for gl{filter,mixer,src}bin too --- ext/gl/gstglfilterbin.c | 4 +++- ext/gl/gstglmixerbin.c | 4 +++- ext/gl/gstglsrcbin.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ext/gl/gstglfilterbin.c b/ext/gl/gstglfilterbin.c index 1dd43350aa..397db73005 100644 --- a/ext/gl/gstglfilterbin.c +++ b/ext/gl/gstglfilterbin.c @@ -222,8 +222,10 @@ gst_gl_filter_bin_set_property (GObject * object, guint prop_id, if (self->filter) gst_bin_remove (GST_BIN (self), self->filter); self->filter = filter; - if (filter) + if (filter) { + gst_object_ref_sink (filter); _connect_filter_element (self); + } break; } default: diff --git a/ext/gl/gstglmixerbin.c b/ext/gl/gstglmixerbin.c index d18c2d31e4..75816e1493 100644 --- a/ext/gl/gstglmixerbin.c +++ b/ext/gl/gstglmixerbin.c @@ -396,8 +396,10 @@ gst_gl_mixer_bin_set_property (GObject * object, /* FIXME: deal with replacing a mixer */ g_return_if_fail (!self->mixer || (self->mixer == mixer)); self->mixer = mixer; - if (mixer) + if (mixer) { + gst_object_ref_sink (mixer); _connect_mixer_element (self); + } break; } default: diff --git a/ext/gl/gstglsrcbin.c b/ext/gl/gstglsrcbin.c index 2afbac56a0..9eb66d3ca3 100644 --- a/ext/gl/gstglsrcbin.c +++ b/ext/gl/gstglsrcbin.c @@ -191,8 +191,10 @@ gst_gl_src_bin_set_property (GObject * object, guint prop_id, if (self->src) gst_bin_remove (GST_BIN (self), self->src); self->src = src; - if (src) + if (src) { + gst_object_ref_sink (src); _connect_src_element (self); + } break; } default: