rgvolume: Avoid taking unnecessary refs

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=733122
This commit is contained in:
Sebastian Rasmussen 2014-07-13 16:05:56 +02:00 committed by Sebastian Dröge
parent ca22ad8da9
commit f45657f604

View file

@ -320,14 +320,14 @@ gst_rg_volume_init (GstRgVolume * self)
volume_pad = gst_element_get_static_pad (self->volume_element, "sink");
ghost_pad = gst_ghost_pad_new_from_template ("sink", volume_pad,
gst_pad_get_pad_template (volume_pad));
GST_PAD_PAD_TEMPLATE (volume_pad));
gst_object_unref (volume_pad);
gst_pad_set_event_function (ghost_pad, gst_rg_volume_sink_event);
gst_element_add_pad (GST_ELEMENT_CAST (self), ghost_pad);
volume_pad = gst_element_get_static_pad (self->volume_element, "src");
ghost_pad = gst_ghost_pad_new_from_template ("src", volume_pad,
gst_pad_get_pad_template (volume_pad));
GST_PAD_PAD_TEMPLATE (volume_pad));
gst_object_unref (volume_pad);
gst_element_add_pad (GST_ELEMENT_CAST (self), ghost_pad);
}