Skip to content

Commit 8504800

Browse files
committed
Fix TestBuilder FacetLocator to handle empty geoms
1 parent 12ca77d commit 8504800

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

modules/app/src/main/java/org/locationtech/jtstest/testbuilder/geom/FacetLocater.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,9 @@ private void findLocations(Stack<Integer> path, Polygon poly, List<GeometryLocat
125125

126126
private void findLocations(Stack<Integer> path, Geometry compGeom, CoordinateSequence seq, List<GeometryLocation> locations)
127127
{
128+
if (seq.size() < 1)
129+
return;
130+
128131
int lastVertexIndexAdded = -1;
129132
Coordinate p0 = seq.getCoordinate(0);
130133
if (p0.distance(queryPt) <= tolerance) {

0 commit comments

Comments
 (0)