summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Kost <ensonic@users.sf.net>2010-09-28 13:52:29 +0300
committerStefan Kost <ensonic@users.sf.net>2010-10-02 18:27:14 +0300
commit7ae63847a8c3455338c155448a309623d74cdf22 (patch)
treef6386d25ef3b84e08ecceda2c946bac91f77f5bf
parent2d699010e93bb610a89e606780fed6a6b070a847 (diff)
valve: no need to ref the object in _chain
Don't ref the pad in chain, like elsewhere
-rw-r--r--gst/valve/gstvalve.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/gst/valve/gstvalve.c b/gst/valve/gstvalve.c
index 4192074e5..977a4afa0 100644
--- a/gst/valve/gstvalve.c
+++ b/gst/valve/gstvalve.c
@@ -180,7 +180,7 @@ gst_valve_get_property (GObject * object,
static GstFlowReturn
gst_valve_chain (GstPad * pad, GstBuffer * buffer)
{
- GstValve *valve = GST_VALVE (gst_pad_get_parent_element (pad));
+ GstValve *valve = GST_VALVE (GST_OBJECT_PARENT (pad));
GstFlowReturn ret = GST_FLOW_OK;
if (g_atomic_int_get (&valve->drop)) {
@@ -202,8 +202,6 @@ gst_valve_chain (GstPad * pad, GstBuffer * buffer)
if (g_atomic_int_get (&valve->drop))
ret = GST_FLOW_OK;
- gst_object_unref (valve);
-
return ret;
}