Opened 3 years ago
Closed 3 years ago
#5152 closed defect (fixed)
ST_Split goes into infinite loop with empty geometries
Reported by: | robe | Owned by: | pramsey |
---|---|---|---|
Priority: | blocker | Milestone: | PostGIS 2.5.7 |
Component: | postgis | Version: | 3.2.x |
Keywords: | Cc: |
Description (last modified by )
SELECT ST_Split('LINESTRING EMPTY'::geometry, ST_Point(10,50)) As result
with recurring notice:
NOTICE: lwgeom_api.c [138] called with n=511880 and npoints=0 NOTICE: lwgeom_api.c [138] called with n=511881 and npoints=0
Change History (11)
comment:1 by , 3 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:2 by , 3 years ago
Description: | modified (diff) |
---|---|
Resolution: | fixed |
Status: | closed → reopened |
ahem strk the endless loop is still there.
comment:3 by , 3 years ago
Oops, I overlooked the "infinite loop" part. How back in stable branches did you guys test ?
comment:4 by , 3 years ago
Do you like this fix ? https://gitlab.com/postgis/postgis/-/merge_requests/82
Results in GEOMETRYCOLLECTION(LINESTRING EMPTY)
output, on the basis of the documented fact that if a blade does not intersect a line, the returned collection will return the full input untouched (which in this case was empty)
comment:5 by , 3 years ago
I only tested master, but assumed it probably has been there for a while. I'm going to commit my garden test changes to master and then the other branches to see how far it goes.
comment:7 by , 3 years ago
I pushed to master, needs be backported still, but I'm not going to have time any soon (feel free to backport, it's a single commit, needs NEWS entry in each back branch)
In 34007a2/git: