some fuzzer fixes
should fix three or four of the PathOp asserts
triggered by the fuzzer tool.
R=kjlubick@google.com
Bug: skia:
Change-Id: I470895addf1e922da6a7c41d44d54eca92e68fb6
Reviewed-on: https://skia-review.googlesource.com/113163
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Cary Clark <caryclark@skia.org>
diff --git a/src/pathops/SkOpSpan.cpp b/src/pathops/SkOpSpan.cpp
index 28989d9..f5195ed 100644
--- a/src/pathops/SkOpSpan.cpp
+++ b/src/pathops/SkOpSpan.cpp
@@ -24,8 +24,7 @@
return ptT;
}
}
- SkASSERT(0); // should never return deleted
- return this;
+ return nullptr; // should never return deleted; caller must abort
}
bool SkOpPtT::contains(const SkOpPtT* check) const {
@@ -269,12 +268,6 @@
fSpanAdds += span->fSpanAdds;
}
-SkOpSpanBase* SkOpSpanBase::active() {
- SkOpSpanBase* result = fPrev ? fPrev->next() : upCast()->next()->prev();
- SkASSERT(this == result || fDebugDeleted);
- return result;
-}
-
// please keep in sync with debugCheckForCollapsedCoincidence()
void SkOpSpanBase::checkForCollapsedCoincidence() {
SkOpCoincidence* coins = this->globalState()->coincidence();