segmentclip: fix wrong pad template unref
authorTim-Philipp Müller <tim@centricular.net>
Thu, 13 Sep 2012 00:26:28 +0000 (01:26 +0100)
committerTim-Philipp Müller <tim@centricular.net>
Thu, 13 Sep 2012 00:26:28 +0000 (01:26 +0100)
Blows up when trying to instantiate a second clip element
of the same type, like in the generic/states unit test.

gst/segmentclip/gstsegmentclip.c

index c09a72293cc91048289aff35f8de524c4ef1368d..5e09152b0c1d41f68813690f80c87cb5968a1dd6 100644 (file)
@@ -104,8 +104,6 @@ gst_segment_clip_init (GstSegmentClip * self, GstSegmentClipClass * g_class)
   GST_PAD_SET_PROXY_ALLOCATION (self->sinkpad);
   gst_element_add_pad (GST_ELEMENT (self), self->sinkpad);
 
-  gst_object_unref (templ);
-
   templ = gst_element_class_get_pad_template (element_class, "src");
   g_assert (templ);