]> granicus.if.org Git - postgis/commitdiff
Fixed bug in definition of distance_spheroid.
authorSandro Santilli <strk@keybit.net>
Mon, 24 Jan 2005 18:11:50 +0000 (18:11 +0000)
committerSandro Santilli <strk@keybit.net>
Mon, 24 Jan 2005 18:11:50 +0000 (18:11 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@1338 b70326c6-7e19-0410-871a-916f4a2858ee

lwgeom/lwgeom_spheroid.c

index e322ce5b01ed1c5cfe2bcd74ed9f4b55460b643b..006d7f91c0424490369f831cd9992a7b453712dc 100644 (file)
@@ -485,12 +485,12 @@ double distance_sphere_method(double lat1, double long1,double lat2,double long2
 
 //distance (geometry,geometry, sphere)
 // -geometrys MUST be points
-PG_FUNCTION_INFO_V1(distance_ellipsoid);
+PG_FUNCTION_INFO_V1(LWGEOM_distance_ellipsoid_point);
 Datum LWGEOM_distance_ellipsoid_point(PG_FUNCTION_ARGS)
 {
-       SPHEROID *sphere = (SPHEROID *)PG_GETARG_POINTER(2);
        PG_LWGEOM *geom1 = (PG_LWGEOM *)PG_DETOAST_DATUM(PG_GETARG_DATUM(0));
        PG_LWGEOM *geom2 = (PG_LWGEOM *)PG_DETOAST_DATUM(PG_GETARG_DATUM(1));
+       SPHEROID *sphere = (SPHEROID *)PG_GETARG_POINTER(2);
        LWPOINT *point1, *point2;
        POINT2D *p1, *p2;