eval: Fix eval test with ftrapv

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2012-10-09 05:55:15 +02:00
parent e73bac484f
commit 03f5043f5d

View File

@ -258,7 +258,7 @@ static double eval_expr(Parser *p, AVExpr *e)
case e_gte: return e->value * (d >= d2 ? 1.0 : 0.0);
case e_pow: return e->value * pow(d, d2);
case e_mul: return e->value * (d * d2);
case e_div: return e->value * (d / d2);
case e_div: return e->value * ((!CONFIG_FTRAPV || d2 ) ? (d / d2) : d * INFINITY);
case e_add: return e->value * (d + d2);
case e_last:return e->value * d2;
case e_st : return e->value * (p->var[av_clip(d, 0, VARS-1)]= d2);