diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2015-03-12 02:01:33 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2015-03-12 15:31:41 +0100 |
commit | 27191b82de0b28ead9b3dcce5aaf1933087fd5fb (patch) | |
tree | fbe80ae4057231fa43d6eda32f3531385158f1e3 /libavcodec/vp9.c | |
parent | b7cb8b3d436f9a571f87ca57fe23f46a9906a9ec (diff) | |
download | ffmpeg-27191b82de0b28ead9b3dcce5aaf1933087fd5fb.tar.gz |
avcodec/vp9: Fix undefined shifts in decode_frame_header()
Found-by: Clang -fsanitize=shift
Reported-by: Thierry Foucu <tfoucu@google.com>
Reviewed-by: "Ronald S. Bultje" <rsbultje@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/vp9.c')
-rw-r--r-- | libavcodec/vp9.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c index 265dc7ed5d..0405c051d9 100644 --- a/libavcodec/vp9.c +++ b/libavcodec/vp9.c @@ -689,10 +689,10 @@ static int decode_frame_header(AVCodecContext *ctx, for (j = 1; j < 4; j++) { s->segmentation.feat[i].lflvl[j][0] = av_clip_uintp2(lflvl + ((s->lf_delta.ref[j] + - s->lf_delta.mode[0]) << sh), 6); + s->lf_delta.mode[0]) * (1 << sh)), 6); s->segmentation.feat[i].lflvl[j][1] = av_clip_uintp2(lflvl + ((s->lf_delta.ref[j] + - s->lf_delta.mode[1]) << sh), 6); + s->lf_delta.mode[1]) * (1 << sh)), 6); } } |