Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#3225 closed defect (fixed)

unchecked return value returned by _lwt_CheckEdgeCrossing()

Reported by: esseffe Owned by: strk
Priority: high Milestone: PostGIS 2.2.0
Component: topology Version: master
Keywords: Cc:


_lwt_CheckEdgeCrossing() is called twice within the lwgeom_topo.c source (near lines 766 and 2144), and in both cases its return value is systematically ignored.

a more robust implementation should always test the return value then immediately returning an error when this function identifies a topology inconsistency, something like this:

   if ( ! skipISOChecks )
-   _lwt_CheckEdgeCrossing( topo, startNode, endNode, geom );
+ {
+    if (_lwt_CheckEdgeCrossing( topo, startNode, endNode, geom ) < 0)
+        return -1;
+ }

Change History (3)

comment:1 by robe, 8 years ago

Component: liblwgeomtopology
Owner: changed from pramsey to strk

comment:2 by strk, 8 years ago

Resolution: fixed
Status: newclosed

Thanks, fixed by r13876

comment:3 by strk, 8 years ago

Version: 2.1.xtrunk
Note: See TracTickets for help on using tickets.