#602 closed defect (fixed)
[JTS works] GEOSOffsetCurve: IllegalArgumentException: RobustDeterminant encountered non-finite numbers
Reported by: | strk | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 3.3.9 |
Component: | Default | Version: | 3.3.6 |
Severity: | Unassigned | Keywords: | |
Cc: |
Description
Bug report origin: http://trac.osgeo.org/postgis/ticket/2099 Offending input (hexwkb): 010200000004000000B788150E6FB162407FABDE5E1D453AC00FB54CBB6EB162409E19426B1B453AC00FB54CBB6EB162409E19426B1B453AC033FBDBB16EB16240F24ABC1F1B453AC0 Operation: GEOSOffsetCurve(geom1_, 0, 0, GEOSBUF_JOIN_ROUND, 2);
Change History (12)
comment:1 by , 11 years ago
comment:3 by , 11 years ago
Milestone: | 3.3.7 → 3.3.x |
---|
comment:4 by , 11 years ago
NOTE: the same error occurs when passing a zero-length line to the function. Taking 5.6e-05 the same as zero may or may not be a solvable bug. I wonder if JTS survives this one.
comment:5 by , 11 years ago
This works in JTS as near as I can tell. A zero-length line works as well.
comment:6 by , 11 years ago
Summary: | GEOSOffsetCurve: IllegalArgumentException: RobustDeterminant encountered non-finite numbers → [JTS works] GEOSOffsetCurve: IllegalArgumentException: RobustDeterminant encountered non-finite numbers |
---|
MArtin: what does JTS return as an OffsetCurve from a zero-length line ?
comment:8 by , 11 years ago
The problem seems to originate in an attempt by OffsetegmentGenerator to compute the offset of a zero or close-to-zero length segment, which results in a NaN ordinate offset. I guess it could be worked around this by omitting the zero or too-short segment from the list (I'm surprised this isn't done already by the simplification step).
comment:9 by , 11 years ago
This is even worst, crashes the lib: LINESTRING(140 -26,149 -26.,149 -26.,149 -26)
comment:10 by , 11 years ago
To recap, this one throws an exception:
LINESTRING(0 1,0 2,0 2,0 0)
And this one aborts:
LINESTRING(0 1,0 2,0 2)
Pretty stable functionality ! :P
comment:11 by , 11 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
For the record: the line has a computed length of 5.58135564343909e-05 units. Here's how the WKT looks like: