| Index: src/utils/SkDashPath.cpp
|
| diff --git a/src/utils/SkDashPath.cpp b/src/utils/SkDashPath.cpp
|
| index 3c4aef343d3399bbc8f30a846116063537499cea..4b2b33d2c4a1bf2ced56dcdd3d13ddf4772a0f29 100644
|
| --- a/src/utils/SkDashPath.cpp
|
| +++ b/src/utils/SkDashPath.cpp
|
| @@ -115,14 +115,15 @@ static bool cull_path(const SkPath& srcPath, const SkStrokeRec& rec,
|
| SkScalar minX = pts[0].fX;
|
| SkScalar maxX = pts[1].fX;
|
|
|
| - if (maxX < bounds.fLeft || minX > bounds.fRight) {
|
| - return false;
|
| - }
|
| -
|
| if (dx < 0) {
|
| SkTSwap(minX, maxX);
|
| }
|
|
|
| + SkASSERT(minX <= maxX);
|
| + if (maxX < bounds.fLeft || minX > bounds.fRight) {
|
| + return false;
|
| + }
|
| +
|
| // Now we actually perform the chop, removing the excess to the left and
|
| // right of the bounds (keeping our new line "in phase" with the dash,
|
| // hence the (mod intervalLength).
|
|
|