Permalink
Browse files

Fix Xcode7 compile error: Absolute value function 'fabsf' given an ar…

…gument of type 'double' but has parameter of type 'float' which may cause truncation of value
  • Loading branch information...
yaokaige committed Sep 23, 2015
1 parent 55b9046 commit 1ec919bd1218630f2560fb54a87ca33c42eaf0f8
Showing with 1 addition and 1 deletion.
  1. +1 −1 Inkpad-Core/SVG/WDSVGPathParser.m
@@ -121,7 +121,7 @@ BOOL decomposeArcToCubic(CGMutablePathRef path, float angle, float rx, float ry,
// Some results of atan2 on some platform implementations are not exact enough. So that we get more
// cubic curves than expected here. Adding 0.001f reduces the count of segments to the correct count.
- int segments = ceilf(fabsf(thetaArc / (M_PI_2 + 0.001f)));
+ int segments = ceilf(fabs(thetaArc / (M_PI_2 + 0.001f)));
for (int i = 0; i < segments; ++i) {
float startTheta = theta1 + i * thetaArc / segments;
float endTheta = theta1 + (i + 1) * thetaArc / segments;

0 comments on commit 1ec919b

Please sign in to comment.