[FFmpeg-devel] [PATCH] avcodec/utils: Assert that the number of consumed bytes in avcodec_decode_audio4() is <= the input size
Michael Niedermayer
michael at niedermayer.cc
Sat Apr 23 21:28:01 CEST 2016
On Sat, Apr 23, 2016 at 05:41:49PM +0200, wm4 wrote:
> On Sat, 23 Apr 2016 17:34:56 +0200
> Michael Niedermayer <michael at niedermayer.cc> wrote:
>
> > Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> > ---
> > 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;
> > }
> >
>
> If you're confident that this actually holds true for all decoders,
> fine.
i couldnt find a file for which this fails and decoders failing this
really are buggy and should be fixed (i volunteer to fix any, please
CC me if anyone finds one)
applied
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
In fact, the RIAA has been known to suggest that students drop out
of college or go to community college in order to be able to afford
settlements. -- The RIAA
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20160423/ab585e75/attachment.sig>
More information about the ffmpeg-devel
mailing list