On Fri, Nov 18, 2011 at 11:34:51AM +0200, Martin Storsjö wrote:
> From: Michael Niedermayer <[email protected]>
> 
> Signed-off-by: Michael Niedermayer <[email protected]>
> ---
>  libavcodec/cinepak.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/libavcodec/cinepak.c b/libavcodec/cinepak.c
> index e66a1c0..a858d6e 100644
> --- a/libavcodec/cinepak.c
> +++ b/libavcodec/cinepak.c
> @@ -370,6 +370,8 @@ static int cinepak_decode (CinepakContext *s)
>          s->strips[i].x2 = s->avctx->width;
>  
>          strip_size = AV_RB24 (&s->data[1]) - 12;
> +        if (strip_size < 0)
> +            return -1;
>          s->data   += 12;
>          strip_size = ((s->data + strip_size) > eod) ? (eod - s->data) : 
> strip_size;
>  
> -- 

looks OK
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to