[FFmpeg-devel] [PATCH] qdm2 decoder: return actually used data size

Reimar Döffinger Reimar.Doeffinger
Sun Dec 12 14:40:37 CET 2010

currently the qdm2 decoder always returns the input buffer size.
IMO it should instead return how much of the data it actually used.
This allows e.g. playing a qdm2 stream even if somehow some packets
become mangled together (happens e.g. with MPlayer's mov demuxer).
Any objections?
Index: ffmpeg/libavcodec/qdm2.c
--- ffmpeg/libavcodec/qdm2.c    (revision 25928)
+++ ffmpeg/libavcodec/qdm2.c    (working copy)
@@ -1971,7 +1971,7 @@
     *data_size = (uint8_t*)out - (uint8_t*)data;
-    return buf_size;
+    return s->checksum_size;
 AVCodec qdm2_decoder =

More information about the ffmpeg-devel mailing list