From ac78014f0b1f219a596d3c0cd803cf6b84191886 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Wed, 1 Jul 2015 15:41:29 +0200 Subject: [PATCH] avcodec/motion_est: Fix some undefined shifts Fixes: asan_heap-oob_1dd60fd_1049_cov_4200102444_P4250048.MOV Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer --- libavcodec/motion_est.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libavcodec/motion_est.c b/libavcodec/motion_est.c index 9e184df74a..477a6827ce 100644 --- a/libavcodec/motion_est.c +++ b/libavcodec/motion_est.c @@ -426,13 +426,13 @@ static int sad_hpel_motion_search(MpegEncContext * s, my > ymin && my < ymax) { int dx=0, dy=0; int d, pen_x, pen_y; - const int index= (my<