diff options
author | Wim Taymans <wim.taymans@collabora.co.uk> | 2010-12-28 11:41:49 +0100 |
---|---|---|
committer | Wim Taymans <wim.taymans@collabora.co.uk> | 2010-12-28 11:44:09 +0100 |
commit | c665034742f8f4e5e702ac61e8d26ed6d64f242f (patch) | |
tree | 05ec214cdc00d39b924237a312d1d7bd886bd011 | |
parent | 85cafac6af27a3f46cd7ffcce1ff503810cafc11 (diff) |
basedepay: fix refcounting issue
Make sure that when _make_writable() returns a new buffer, we actually push that
one instead of the old one.
-rw-r--r-- | gst-libs/gst/rtp/gstbasertpdepayload.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/gst-libs/gst/rtp/gstbasertpdepayload.c b/gst-libs/gst/rtp/gstbasertpdepayload.c index d1d39916d..fdc861d20 100644 --- a/gst-libs/gst/rtp/gstbasertpdepayload.c +++ b/gst-libs/gst/rtp/gstbasertpdepayload.c @@ -559,11 +559,11 @@ gst_base_rtp_depayload_prepare_push (GstBaseRTPDepayload * filter, data.bclass = GST_BASE_RTP_DEPAYLOAD_GET_CLASS (filter); if (is_list) { - gst_buffer_list_foreach (GST_BUFFER_LIST_CAST (obj), - (GstBufferListFunc) set_headers, &data); + GstBufferList **blist = obj; + gst_buffer_list_foreach (*blist, (GstBufferListFunc) set_headers, &data); } else { - GstBuffer *buf = GST_BUFFER_CAST (obj); - set_headers (&buf, 0, 0, &data); + GstBuffer **buf = obj; + set_headers (buf, 0, 0, &data); } /* if this is the first buffer send a NEWSEGMENT */ @@ -605,7 +605,7 @@ gst_base_rtp_depayload_push_ts (GstBaseRTPDepayload * filter, guint32 timestamp, res = gst_base_rtp_depayload_prepare_push (filter, TRUE, timestamp, FALSE, - out_buf); + &out_buf); if (G_LIKELY (res == GST_FLOW_OK)) res = gst_pad_push (filter->srcpad, out_buf); @@ -634,7 +634,7 @@ gst_base_rtp_depayload_push (GstBaseRTPDepayload * filter, GstBuffer * out_buf) { GstFlowReturn res; - res = gst_base_rtp_depayload_prepare_push (filter, FALSE, 0, FALSE, out_buf); + res = gst_base_rtp_depayload_prepare_push (filter, FALSE, 0, FALSE, &out_buf); if (G_LIKELY (res == GST_FLOW_OK)) res = gst_pad_push (filter->srcpad, out_buf); @@ -662,7 +662,7 @@ gst_base_rtp_depayload_push_list (GstBaseRTPDepayload * filter, { GstFlowReturn res; - res = gst_base_rtp_depayload_prepare_push (filter, TRUE, 0, TRUE, out_list); + res = gst_base_rtp_depayload_prepare_push (filter, TRUE, 0, TRUE, &out_list); if (G_LIKELY (res == GST_FLOW_OK)) res = gst_pad_push_list (filter->srcpad, out_list); |