On Sat, 29 Sep 2012 11:18:21 +0200, Jindřich Makovička <[email protected]> wrote: > On Thu, Sep 27, 2012 at 11:56 PM, Ronald S. Bultje <[email protected]> wrote: > >> In h264.c, it could be fixed by skipping junk bytes at the end of > >> buffer, when searching for a start code. > >> When there are only three bytes after NAL_END_SEQUENCE, the buffer > >> pointer gets stuck otherwise. > >> > >> --- a/libavcodec/h264.c > >> +++ b/libavcodec/h264.c > >> @@ -3694,8 +3694,10 @@ static int decode_nal_units(H264Context *h, > >> const uint8_t *buf, int buf_size) > >> buf[buf_index + 2] == 1) > >> break; > >> > >> - if (buf_index + 3 >= buf_size) > >> + if (buf_index + 3 >= buf_size) { > >> + buf_index = buf_size; > >> break; > >> + } > > > > I'm fine with this. > > > > Ronald > > _______________________________________________ > > libav-devel mailing list > > [email protected] > > https://lists.libav.org/mailman/listinfo/libav-devel > > Here is a proper patch. >
Pushed. -- Anton Khirnov _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
