[FFmpeg-devel] [PATCH] avcodec/h264dec: check number of SPS in is_extra
--- libavcodec/h264dec.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavcodec/h264dec.c b/libavcodec/h264dec.c index bffce52..6f7530d 100644 --- a/libavcodec/h264dec.c +++ b/libavcodec/h264dec.c @@ -871,6 +871,8 @@ static int is_extra(const uint8_t *buf, int buf_size) { int cnt= buf[5]&0x1f; const uint8_t *p= buf+6; +if (!cnt) +return 0; while(cnt--){ int nalsize= AV_RB16(p) + 2; if(nalsize > buf_size - (p-buf) || (p[2] & 0x9F) != 7) -- 2.9.5 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avcodec/h264dec: check number of SPS in is_extra
On Thu, Sep 06, 2018 at 05:15:11PM +0800, Zhao Zhili wrote: > --- > libavcodec/h264dec.c | 2 ++ > 1 file changed, 2 insertions(+) will apply thx [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Breaking DRM is a little like attempting to break through a door even though the window is wide open and the only thing in the house is a bunch of things you dont want and which you would get tomorrow for free anyway signature.asc Description: PGP signature ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel