[FFmpeg-cvslog] r13481 - trunk/libavcodec/motion_est.c

Baptiste Coudurier baptiste.coudurier
Wed May 28 03:15:07 CEST 2008


Hi Michael,

michael wrote:
> Author: michael
> Date: Wed May 28 01:41:10 2008
> New Revision: 13481
> 
> Log:
> Check dia size a little more. Fixes CID80.
> 
> 
> Modified:
>    trunk/libavcodec/motion_est.c
> 
> Modified: trunk/libavcodec/motion_est.c
> ==============================================================================
> --- trunk/libavcodec/motion_est.c	(original)
> +++ trunk/libavcodec/motion_est.c	Wed May 28 01:41:10 2008
> @@ -235,6 +235,12 @@ void ff_init_me(MpegEncContext *s){
>      MotionEstContext * const c= &s->me;
>      int cache_size= FFMIN(ME_MAP_SIZE>>ME_MAP_SHIFT, 1<<ME_MAP_SHIFT);
>      int dia_size= FFMAX(FFABS(s->avctx->dia_size)&255, FFABS(s->avctx->pre_dia_size)&255);
> +
> +    if(FFMIN(s->avctx->dia_size, s->avctx->pre_dia_size) < -ME_MAP_SIZE){
> +        av_log(s->avctx, AV_LOG_ERROR, "ME_MAP size is too small for SAB diamond\n");
> +        return -1;
> +    }
> +

ff_init_me returns void:
libavcodec/motion_est.c:241: warning: 'return' with a value, in function
returning void

-- 
Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
Smartjog USA Inc.                                http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA




More information about the ffmpeg-cvslog mailing list