mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-21 10:55:51 +02:00
avcodec/vc1_pred: Fix undefined shift in ff_vc1_pred_mv()
Found-by: Clang -fsanitize=shift Reported-by: Thierry Foucu <tfoucu@google.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
1932f7e2ee
commit
e5dfa43619
@ -231,8 +231,10 @@ void ff_vc1_pred_mv(VC1Context *v, int n, int dmv_x, int dmv_y,
|
||||
else
|
||||
mixedmv_pic = 0;
|
||||
/* scale MV difference to be quad-pel */
|
||||
dmv_x <<= 1 - s->quarter_sample;
|
||||
dmv_y <<= 1 - s->quarter_sample;
|
||||
if (!s->quarter_sample) {
|
||||
dmv_x *= 2;
|
||||
dmv_y *= 2;
|
||||
}
|
||||
|
||||
wrap = s->b8_stride;
|
||||
xy = s->block_index[n];
|
||||
|
Loading…
Reference in New Issue
Block a user