[postgis-tickets] [PostGIS] #2185: Geometry output functions crash server with invalid WKT
PostGIS
trac at osgeo.org
Wed Jan 23 22:59:17 PST 2013
#2185: Geometry output functions crash server with invalid WKT
------------------------+---------------------------------------------------
Reporter: mwtoews | Owner: pramsey
Type: defect | Status: new
Priority: blocker | Milestone: PostGIS 2.0.3
Component: postgis | Version: 2.0.x
Keywords: windows 64 |
------------------------+---------------------------------------------------
Comment(by robe):
Yap immuatable is playing a curious role in this bug. I created a version
of the ST_AsText without IMMUTABLE:
{{{
CREATE OR REPLACE FUNCTION st_astextNotImmut(text)
RETURNS text AS
' SELECT ST_AsText($1::geometry); '
LANGUAGE sql STRICT
COST 100;
}}}
and it does not crash. I can call this as many times to my hearts
content.
{{{
SELECT ST_AsTextNotImmut('POINT Z(3 4 hi)');
}}}
and no crashing. So I guess as a temporary fix you could remove the
IMMUTABLE by redefining as this.
{{{
CREATE OR REPLACE FUNCTION ST_AsText(text)
RETURNS text AS
' SELECT ST_AsText($1::geometry); '
LANGUAGE sql STRICT
COST 100;
}}}
until we figure out what exactly immutable is doing to cause the crash.
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/2185#comment:15>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list