Commit 9f0fcd14 authored by Jeremy Huddleston's avatar Jeremy Huddleston Committed by Adam Jackson

randr: Correct a miscall of abs() to instead call fabs()

rrtransform.c:124:22: warning: using integer absolute value function 'abs' when
      argument is of floating point type [-Wabsolute-value,Semantic Issue]
            if ((v = abs(f_transform->m[j][i])) > max)
                     ^
rrtransform.c:124:22: note: use function 'fabs' instead [Semantic Issue]
            if ((v = abs(f_transform->m[j][i])) > max)
                     ^~~
                     fabs
Signed-off-by: default avatarJeremy Huddleston Sequoia <jeremyhu@apple.com>
Reviewed-by: default avatarAlan Coopersmith <alan.coopersmith@oracle.com>
parent 610dd8a5
......@@ -121,7 +121,7 @@ RRTransformRescale(struct pixman_f_transform *f_transform, double limit)
for (j = 0; j < 3; j++)
for (i = 0; i < 3; i++)
if ((v = abs(f_transform->m[j][i])) > max)
if ((v = fabs(f_transform->m[j][i])) > max)
max = v;
scale = limit / max;
for (j = 0; j < 3; j++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment