[FFmpeg-cvslog] sab_diamond_search: add assert to double check the minima_count
Michael Niedermayer
git at videolan.org
Sun Nov 4 13:24:49 CET 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sun Nov 4 04:46:53 2012 +0100| [bbd7b46b94ee8e8d668f950c65ec470fa43ede79] | committer: Michael Niedermayer
sab_diamond_search: add assert to double check the minima_count
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=bbd7b46b94ee8e8d668f950c65ec470fa43ede79
---
libavcodec/motion_est_template.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libavcodec/motion_est_template.c b/libavcodec/motion_est_template.c
index 07bfc00..2b1c6e1 100644
--- a/libavcodec/motion_est_template.c
+++ b/libavcodec/motion_est_template.c
@@ -688,6 +688,8 @@ static int sab_diamond_search(MpegEncContext * s, int *best, int dmin,
LOAD_COMMON2
unsigned map_generation = c->map_generation;
+ av_assert1(minima_count <= MAX_SAB_SIZE);
+
cmpf= s->dsp.me_cmp[size];
chroma_cmpf= s->dsp.me_cmp[size+1];
More information about the ffmpeg-cvslog
mailing list