diff options
author | Olivier CrĂȘte <olivier.crete@collabora.co.uk> | 2009-07-16 15:43:46 -0400 |
---|---|---|
committer | Olivier CrĂȘte <olivier.crete@collabora.co.uk> | 2009-07-16 15:47:08 -0400 |
commit | cee75e2c891ac95264dd13adc071bb3f10adcc15 (patch) | |
tree | 21c0d03a14ab7d76ce332db395dc0fc37550d90b /ext | |
parent | 8eac8701ff4ba06702c655dc40bdd9d8eec8fe21 (diff) | |
download | gst-plugins-bad-cee75e2c891ac95264dd13adc071bb3f10adcc15.tar.gz gst-plugins-bad-cee75e2c891ac95264dd13adc071bb3f10adcc15.tar.bz2 gst-plugins-bad-cee75e2c891ac95264dd13adc071bb3f10adcc15.zip |
mimdec: Don't try to parse the header before dropping the paused frames
Diffstat (limited to 'ext')
-rw-r--r-- | ext/mimic/gstmimdec.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/ext/mimic/gstmimdec.c b/ext/mimic/gstmimdec.c index f06473ba..1323b154 100644 --- a/ext/mimic/gstmimdec.c +++ b/ext/mimic/gstmimdec.c @@ -181,6 +181,12 @@ gst_mimdec_chain (GstPad * pad, GstBuffer * in) goto out; } + if (header[1] == 1) { + /* This is a a paused frame, skip it */ + gst_adapter_flush (mimdec->adapter, 24); + continue; + } + fourcc = GUINT32_FROM_LE (*((guint32 *) (header + 12))); if (GST_MAKE_FOURCC ('M', 'L', '2', '0') != fourcc) { GST_WARNING_OBJECT (mimdec, "invalid frame: unknown FOURCC code" @@ -201,12 +207,6 @@ gst_mimdec_chain (GstPad * pad, GstBuffer * in) mimdec->have_header = TRUE; } - /* Check if its paused frame, drop it */ - if (mimdec->payload_size == 0) { - mimdec->have_header = FALSE; - continue; - } - if (gst_adapter_available (mimdec->adapter) < mimdec->payload_size) { goto out; } |