summaryrefslogtreecommitdiffstats
path: root/gst/smpte
diff options
context:
space:
mode:
Diffstat (limited to 'gst/smpte')
-rw-r--r--gst/smpte/gstsmpte.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gst/smpte/gstsmpte.c b/gst/smpte/gstsmpte.c
index 44420ac8..5d3101cc 100644
--- a/gst/smpte/gstsmpte.c
+++ b/gst/smpte/gstsmpte.c
@@ -163,6 +163,7 @@ gst_smpte_transition_type_get_type (void)
static void gst_smpte_class_init (GstSMPTEClass * klass);
static void gst_smpte_base_init (GstSMPTEClass * klass);
static void gst_smpte_init (GstSMPTE * smpte);
+static void gst_smpte_finalize (GstSMPTE * smpte);
static GstFlowReturn gst_smpte_collected (GstCollectPads * pads,
GstSMPTE * smpte);
@@ -230,6 +231,7 @@ gst_smpte_class_init (GstSMPTEClass * klass)
gobject_class->set_property = gst_smpte_set_property;
gobject_class->get_property = gst_smpte_get_property;
+ gobject_class->finalize = (GObjectFinalizeFunc) gst_smpte_finalize;
_gst_mask_init ();
@@ -380,6 +382,16 @@ gst_smpte_init (GstSMPTE * smpte)
}
static void
+gst_smpte_finalize (GstSMPTE * smpte)
+{
+ if (smpte->collect) {
+ gst_object_unref (smpte->collect);
+ }
+
+ G_OBJECT_CLASS (parent_class)->finalize ((GObject *) smpte);
+}
+
+static void
gst_smpte_reset (GstSMPTE * smpte)
{
smpte->width = -1;