Opened 12 years ago

Closed 12 years ago

#1771 closed defect (fixed)

TopoGeo_addLineString kills the backend

Reported by: strk Owned by: strk
Priority: critical Milestone: PostGIS 2.0.1
Component: topology Version: 2.0.x
Keywords: Cc:


Again seems related to tolerance (thus ST_Snap):

select createtopology('tt');
select topogeo_addlinestring('tt', 'LINESTRING(0 1, 2 2, 2 0, 0 1)');
select topogeo_addlinestring('tt', 'LINESTRING(1 1, 3 2, 3 0, 1 1)', 10);

The above results in a backend crash here ( POSTGIS="2.0.1SVN r9628" GEOS="3.4.0dev-CAPI-1.8.0" )

Change History (6)

comment:1 by strk, 12 years ago

Wonders, it's not ST_Snap but our nice splitting functions (LRS?):

DEBUG:  Intersecting nodes: MULTIPOINT(0 1)
DEBUG:  Snapped to nodes: LINESTRING(0 1,0 1,0 1,0 1)
DEBUG:  Split by POINT(0 1): MULTILINESTRING((0 1),(-nan -nan,0 1))
DEBUG:  Split: MULTILINESTRING((0 1),(-nan -nan,0 1))

Then the NaN input kills something else…

comment:2 by strk, 12 years ago

Here's the first culprit:

select ST_AsText(ST_Split( 'LINESTRING(0 1,0 1,0 1,0 1)', 'POINT(0 1)' ));


comment:3 by strk, 12 years ago

Not that I know what answer would make sense. How do you split a LINE composed by a single point by that single point ? How many lines do you get in output ? I'm tempted to yell INFINITE ! :D

comment:4 by strk, 12 years ago

Bogus ST_Split return filed as #1772

comment:5 by strk, 12 years ago

And #1773 identifies the crash in ST_UnaryUnion operation performed on the NaN-equipped value…

comment:6 by strk, 12 years ago

Resolution: fixed
Status: newclosed

Alright, now that #1772 is fixed you don't get a NaN anymore, but the second line disappears. I think it's expected.

So this bug (kills the backend) is fixed.

Stay tuned on #1773 for the NaN-killer bug, and see you on next topology issue !

Note: See TracTickets for help on using tickets.