aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/pathops
diff options
context:
space:
mode:
authorGravatar Cary Clark <caryclark@google.com>2016-11-17 08:47:37 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2016-11-17 17:18:52 +0000
commit9de097639f04e5a18da2d2b123dace9d24ab50e4 (patch)
tree9601abbc7e5f3ea59fb771692205e147a152e2b4 /src/pathops
parentbd2d111d233acf62f2f3e1b55c4f9dc8701179ae (diff)
fix fuzzer crash
Fail if data is inconsistent. R=kjlubick@google.com BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4923 Change-Id: Ie3f65c80c0d59968b1e3fc8bc91839bedb2e3da3 Reviewed-on: https://skia-review.googlesource.com/4923 Commit-Queue: Cary Clark <caryclark@google.com> Reviewed-by: Kevin Lubick <kjlubick@google.com>
Diffstat (limited to 'src/pathops')
-rw-r--r--src/pathops/SkOpCoincidence.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/pathops/SkOpCoincidence.cpp b/src/pathops/SkOpCoincidence.cpp
index dadcfa520b..d7ef35f5c4 100644
--- a/src/pathops/SkOpCoincidence.cpp
+++ b/src/pathops/SkOpCoincidence.cpp
@@ -1303,6 +1303,7 @@ bool SkOpCoincidence::mark(DEBUG_COIN_DECLARE_ONLY_PARAMS()) {
}
/* coin and opp spans may not match up. Mark the ends, and then let the interior
get marked as many times as the spans allow */
+ FAIL_IF(!oStart->upCastable());
start->insertCoincidence(oStart->upCast());
end->insertCoinEnd(oEnd);
const SkOpSegment* segment = start->segment();