[FFmpeg-cvslog] avcodec/utils: Assert that the number of consumed bytes in avcodec_decode_audio4() is <= the input size

Michael Niedermayer git at videolan.org
Sat Apr 23 21:30:10 CEST 2016


ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Sat Apr 23 17:23:59 2016 +0200| [38433345e5039ed8fa241d41d6a3bdd2dcb8a278] | committer: Michael Niedermayer

avcodec/utils: Assert that the number of consumed bytes in avcodec_decode_audio4() is <= the input size

Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=38433345e5039ed8fa241d41d6a3bdd2dcb8a278
---

 libavcodec/utils.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index 946ecb9..21ad3cf 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -2422,6 +2422,8 @@ fail:
             av_frame_unref(frame);
     }
 
+    av_assert0(ret <= avpkt->size);
+
     return ret;
 }
 



More information about the ffmpeg-cvslog mailing list