On 11/11/14 17:40, Vittorio Giovara wrote: > Avoid a possible negative bitshift. > > CC: libav-sta...@libav.org > Bug-Id: CID 1194400 > --- > libavcodec/shorten.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/libavcodec/shorten.c b/libavcodec/shorten.c > index c465fff..c93ba6b 100644 > --- a/libavcodec/shorten.c > +++ b/libavcodec/shorten.c > @@ -510,6 +510,8 @@ static int shorten_decode_frame(AVCodecContext *avctx, > void *data, > break; > case FN_BITSHIFT: > s->bitshift = get_ur_golomb_shorten(&s->gb, BITSHIFTSIZE); > + if (s->bitshift < 0) > + return AVERROR_INVALIDDATA; > break; > case FN_BLOCKSIZE: { > unsigned blocksize = get_uint(s, av_log2(s->blocksize)); >
Ok. _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel