flxdec: Flush data from adapter after reading it
authorSebastian Dröge <slomo@circular-chaos.org>
Fri, 24 May 2013 17:31:14 +0000 (19:31 +0200)
committerSebastian Dröge <slomo@circular-chaos.org>
Fri, 24 May 2013 17:31:14 +0000 (19:31 +0200)
Otherwise we're going in an infinite loop, reading the same data
over and over again.

gst/flx/gstflxdec.c

index 5c90a34..0f17e75 100644 (file)
@@ -543,6 +543,7 @@ gst_flxdec_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
       memcpy (&flxfh, data, FlxFrameChunkSize);
       FLX_FRAME_CHUNK_FIX_ENDIANNESS (&flxfh);
       gst_adapter_unmap (flxdec->adapter);
+      gst_adapter_flush (flxdec->adapter, FlxFrameChunkSize);
 
       switch (flxfh.id) {
         case FLX_FRAME_TYPE: