diff options
author | Michael Niedermayer | 2017-04-27 15:10:26 +0200 |
---|---|---|
committer | Michael Niedermayer | 2017-05-03 11:57:34 +0200 |
commit | 48b3117844177d8442bc9fa3ede1d31ce82ae6fc (patch) | |
tree | 6241e88c8508480ceec1c8798049315a5cd803fb /libavcodec/svq3.c | |
parent | 382b4fc9b5f3102f59743bf9c8619b31dd8ede1b (diff) |
avcodec/svq3: Reject dx/dy beyond 16bit
The code does use 16bit sized arrays later so larger deltas would not work
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/svq3.c')
-rw-r--r-- | libavcodec/svq3.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c index 3e35fd73d6..76a465b9c0 100644 --- a/libavcodec/svq3.c +++ b/libavcodec/svq3.c @@ -551,7 +551,7 @@ static inline int svq3_mc_dir(SVQ3Context *s, int size, int mode, dy = get_interleaved_se_golomb(&s->gb_slice); dx = get_interleaved_se_golomb(&s->gb_slice); - if (dx == INVALID_VLC || dy == INVALID_VLC) { + if (dx != (int16_t)dx || dy != (int16_t)dy) { av_log(s->avctx, AV_LOG_ERROR, "invalid MV vlc\n"); return -1; } |