Mercurial > libavcodec.hg
changeset 5087:6c7f4ece59ed libavcodec
check qblur > 1 (prevent assert failure / segfault)
fixes sf bug #797610
author | michael |
---|---|
date | Thu, 31 May 2007 21:40:22 +0000 |
parents | a10ebd496bd9 |
children | 8e206208db1f |
files | ratecontrol.c |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/ratecontrol.c Wed May 30 23:06:37 2007 +0000 +++ b/ratecontrol.c Thu May 31 21:40:22 2007 +0000 @@ -201,6 +201,10 @@ rcc->pass1_rc_eq_output_sum= 0.001; rcc->pass1_wanted_bits=0.001; + if(s->avctx->qblur > 1.0){ + av_log(s->avctx, AV_LOG_ERROR, "qblur too large\n"); + return -1; + } /* init stuff with the user specified complexity */ if(s->avctx->rc_initial_cplx){ for(i=0; i<60*30; i++){