Index: src/core/SkPathMeasure.cpp |
diff --git a/src/core/SkPathMeasure.cpp b/src/core/SkPathMeasure.cpp |
index a5dd84048c56c88334020f1a6d6907b54b918413..c963e9cf356df10868cf98be3daee42b03d2926a 100644 |
--- a/src/core/SkPathMeasure.cpp |
+++ b/src/core/SkPathMeasure.cpp |
@@ -341,7 +341,8 @@ |
if (SK_Scalar1 == stopT) { |
dst->quadTo(tmp0[3], tmp0[4]); |
} else { |
- SkChopQuadAt(&tmp0[2], tmp1, (stopT - startT) / (1 - startT)); |
+ SkChopQuadAt(&tmp0[2], tmp1, SkScalarDiv(stopT - startT, |
+ SK_Scalar1 - startT)); |
dst->quadTo(tmp1[1], tmp1[2]); |
} |
} |
@@ -382,7 +383,8 @@ |
if (SK_Scalar1 == stopT) { |
dst->cubicTo(tmp0[4], tmp0[5], tmp0[6]); |
} else { |
- SkChopCubicAt(&tmp0[3], tmp1, (stopT - startT) / (1 - startT)); |
+ SkChopCubicAt(&tmp0[3], tmp1, SkScalarDiv(stopT - startT, |
+ SK_Scalar1 - startT)); |
dst->cubicTo(tmp1[1], tmp1[2], tmp1[3]); |
} |
} |