From: <sl...@ke...> - 2008-02-28 08:37:53
|
CVS Root: /cvs/gstreamer Module: gst-plugins-good Changes by: slomo Date: Thu Feb 28 2008 08:37:59 UTC Log message: * gst/law/mulaw-decode.c: (gst_mulawdec_chain): Return GST_FLOW_NOT_NEGOTIATED when the caps are not set yet on the srcpad. We need rate and channels before we can do any processing. Fixes bug #519088. Modified files: . : ChangeLog gst/law : mulaw-decode.c Links: http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-plugins-good/ChangeLog.diff?r1=1.3334&r2=1.3335 http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-plugins-good/gst/law/mulaw-decode.c.diff?r1=1.31&r2=1.32 ====Begin Diffs==== Index: ChangeLog =================================================================== RCS file: /cvs/gstreamer/gst-plugins-good/ChangeLog,v retrieving revision 1.3334 retrieving revision 1.3335 diff -u -d -r1.3334 -r1.3335 --- ChangeLog 26 Feb 2008 10:09:35 -0000 1.3334 +++ ChangeLog 28 Feb 2008 08:37:43 -0000 1.3335 @@ -1,3 +1,10 @@ +2008-02-28 Sebastian Dröge <sl...@ci...> + + * gst/law/mulaw-decode.c: (gst_mulawdec_chain): + Return GST_FLOW_NOT_NEGOTIATED when the caps are not set + yet on the srcpad. We need rate and channels before we + can do any processing. Fixes bug #519088. 2008-02-26 Jan Schmidt <jan...@su...> * configure.ac: Index: mulaw-decode.c RCS file: /cvs/gstreamer/gst-plugins-good/gst/law/mulaw-decode.c,v retrieving revision 1.31 retrieving revision 1.32 diff -u -d -r1.31 -r1.32 --- mulaw-decode.c 2 Nov 2007 17:23:43 -0000 1.31 +++ mulaw-decode.c 28 Feb 2008 08:37:44 -0000 1.32 @@ -153,7 +153,12 @@ GstBuffer *outbuf; GstFlowReturn ret; - mulawdec = GST_MULAWDEC (gst_pad_get_parent (pad)); + mulawdec = GST_MULAWDEC (GST_PAD_PARENT (pad)); + if (G_UNLIKELY (mulawdec->srccaps == NULL)) { + gst_buffer_unref (buffer); + return GST_FLOW_NOT_NEGOTIATED; + } mulaw_data = (guint8 *) GST_BUFFER_DATA (buffer); mulaw_size = GST_BUFFER_SIZE (buffer); @@ -179,8 +184,6 @@ ret = gst_pad_push (mulawdec->srcpad, outbuf); - gst_object_unref (mulawdec); - return ret; } |