diff options
author | caryclark <caryclark@google.com> | 2016-09-21 08:46:56 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-09-21 08:46:56 -0700 |
commit | 45f04b8ea8256476d87c677e23d9efbcb0ab937e (patch) | |
tree | 07991a55e31bfb683190566e85749c583c040d99 /src | |
parent | 67fa4e31d885acf74514527a2cc3ed759c05d3c4 (diff) |
fix skia pathops fuzzers
Add isolated tests.
R=kjlubick@google.com
BUG=skia:5775
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2358043002
Review-Url: https://codereview.chromium.org/2358043002
Diffstat (limited to 'src')
-rw-r--r-- | src/pathops/SkDQuadLineIntersection.cpp | 2 | ||||
-rwxr-xr-x | src/pathops/SkOpSpan.cpp | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/src/pathops/SkDQuadLineIntersection.cpp b/src/pathops/SkDQuadLineIntersection.cpp index dc237f57a5..8d5baf6945 100644 --- a/src/pathops/SkDQuadLineIntersection.cpp +++ b/src/pathops/SkDQuadLineIntersection.cpp @@ -99,7 +99,7 @@ public: , fLine(&l) , fIntersections(i) , fAllowNear(true) { - i->setMax(4); // allow short partial coincidence plus discrete intersections + i->setMax(5); // allow short partial coincidence plus discrete intersections } LineQuadraticIntersections(const SkDQuad& q) diff --git a/src/pathops/SkOpSpan.cpp b/src/pathops/SkOpSpan.cpp index 26c6f2522c..0c47b685f0 100755 --- a/src/pathops/SkOpSpan.cpp +++ b/src/pathops/SkOpSpan.cpp @@ -471,6 +471,7 @@ bool SkOpSpan::insertCoincidence(const SkOpSegment* segment, bool flipped, bool if (!ordered) { const SkOpSpanBase* spanEnd = fNext->contains(segment)->span(); const SkOpPtT* start = base->ptT()->starter(spanEnd->ptT()); + FAIL_IF(!start->span()->upCastable()); span = const_cast<SkOpSpan*>(start->span()->upCast()); } else if (flipped) { span = base->prev(); |