From f952ae1400c5bb76642044229e4663925a4b7ff7 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Wed, 15 Aug 2012 01:58:41 +0200 Subject: pafdec: fix wrong check for input buffer size. Signed-off-by: Michael Niedermayer --- libavcodec/paf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/paf.c b/libavcodec/paf.c index 388e2a082c..722ab26888 100644 --- a/libavcodec/paf.c +++ b/libavcodec/paf.c @@ -278,7 +278,7 @@ static int paf_vid_decode(AVCodecContext *avctx, void *data, if (index + count > 256) return AVERROR_INVALIDDATA; - if (bytestream2_get_bytes_left(&c->gb) < 3 * AVPALETTE_SIZE) + if (bytestream2_get_bytes_left(&c->gb) < 3*count) return AVERROR_INVALIDDATA; out += index; -- cgit v1.2.3