[FFmpeg-devel] [PATCH] vp3: Assert on invalid filter_limit values.

Michael Niedermayer michaelni at gmx.at
Fri Apr 13 02:57:26 CEST 2012


On Thu, Apr 12, 2012 at 04:07:10PM -0700, dalecurtis at chromium.org wrote:
> From: Dale Curtis <dalecurtis at chromium.org>
> 
> Signed-off-by: Dale Curtis <dalecurtis at chromium.org>
> ---
>  libavcodec/vp3.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
> index e94264e..e146593 100644
> --- a/libavcodec/vp3.c
> +++ b/libavcodec/vp3.c
> @@ -396,6 +396,7 @@ static void init_loop_filter(Vp3DecodeContext *s)
>      int value;
>  
>      filter_limit = s->filter_limit_values[s->qps[0]];
> +    av_assert0(filter_limit < 128);

applied with the check changed to unsigend so negative values
are caught too

thanks

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Many things microsoft did are stupid, but not doing something just because
microsoft did it is even more stupid. If everything ms did were stupid they
would be bankrupt already.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20120413/22508f5d/attachment.asc>


More information about the ffmpeg-devel mailing list