[postgis-users] Bug fix for transform() function

Mark Cave-Ayland mark.cave-ayland at webbased.co.uk
Wed Sep 4 03:03:43 PDT 2002


Hi everyone,

I have recently found a bug in postgis-0.7.1 to do with the transform()
function which causes the backend server process to die when the query
is executed! I was attempting to reproject a BOX3D object with the
following statement (running this on a production system is probably not
advised):

select transform(setSRID('BOX3D(-9.13027162006
45.0826338462,1.96043607225 56.1733415385)'::BOX3D,4318), 27700);

The reprojection causes the server process to die (and terminates both
the client and the server under cygwin). Looking at the source, I found
that the BOX3D geometry is not handled correctly and so I have modified
it to correctly handle the reprojection of the the BOX3D object.

I have enclosed my patch against 0.7.1 which I think gives the correct
response, although I would be grateful if someone could review it since
I'm not that familiar with the reprojection code. Hopefully it will help
other people experiencing the same problem.


Many thanks,

Mark.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: transform.patch
Type: application/octet-stream
Size: 3685 bytes
Desc: transform.patch
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20020904/8b2404a7/attachment.obj>


More information about the postgis-users mailing list