Index: src/pathops/SkOpCoincidence.cpp |
diff --git a/src/pathops/SkOpCoincidence.cpp b/src/pathops/SkOpCoincidence.cpp |
index 87bb91386975f9d3cb13c9febad906b68c319d02..f56847787c2c146b6da1b43e50636f0bd6f8f7e9 100755 |
--- a/src/pathops/SkOpCoincidence.cpp |
+++ b/src/pathops/SkOpCoincidence.cpp |
@@ -110,11 +110,17 @@ bool SkOpCoincidence::addExpanded(SkChunkAlloc* allocator |
if (startPart < oStartPart) { |
double newT = oStartPtT->fT + oStartRange * startPart; |
newPt = oStart->segment()->addT(newT, SkOpSegment::kAllowAlias, allocator); |
+ if (!newPt) { |
+ return false; |
+ } |
newPt->fPt = test->pt(); |
test->ptT()->addOpp(newPt); |
} else { |
double newT = startPtT->fT + startRange * oStartPart; |
newPt = start->segment()->addT(newT, SkOpSegment::kAllowAlias, allocator); |
+ if (!newPt) { |
+ return false; |
+ } |
newPt->fPt = oTest->pt(); |
oTest->ptT()->addOpp(newPt); |
} |