Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2015-09-11 20:59:17 +0300
committerRonald S. Bultje <rsbultje@gmail.com>2015-09-12 14:01:48 +0300
commita30a8beeb3dc44b666d0e1aefbd823752f321ac1 (patch)
treec402d60fa7e2fec9cb60b725ce0b319c08907c1d /libavcodec/vp9.c
parent2563a33856eb597c9d53b4c7cab07b6f18417740 (diff)
vp9: Fix emu[] edge overflow conditions for >8bpp/non-420.
Diffstat (limited to 'libavcodec/vp9.c')
-rw-r--r--libavcodec/vp9.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c
index c605c08288..a357a5f559 100644
--- a/libavcodec/vp9.c
+++ b/libavcodec/vp9.c
@@ -3301,9 +3301,9 @@ static void decode_b(AVCodecContext *ctx, int row, int col,
// emulated overhangs if the stride of the target buffer can't hold. This
// makes it possible to support emu-edge and so on even if we have large block
// overhangs
- emu[0] = (col + w4) * 8 > f->linesize[0] ||
+ emu[0] = (col + w4) * 8 * bytesperpixel > f->linesize[0] ||
(row + h4) > s->rows;
- emu[1] = (col + w4) * 4 > f->linesize[1] ||
+ emu[1] = ((col + w4) * 8 >> s->ss_h) * bytesperpixel > f->linesize[1] ||
(row + h4) > s->rows;
if (emu[0]) {
s->dst[0] = s->tmp_y;