[postgis-tickets] r15606 - ST_AsGeom optimize POINT case

bjorn at wololo.org bjorn at wololo.org
Tue Aug 29 12:09:43 PDT 2017


Author: bjornharrtell
Date: 2017-08-29 12:09:43 -0700 (Tue, 29 Aug 2017)
New Revision: 15606

Modified:
   trunk/postgis/mvt.c
Log:
ST_AsGeom optimize POINT case

Modified: trunk/postgis/mvt.c
===================================================================
--- trunk/postgis/mvt.c	2017-08-29 16:58:29 UTC (rev 15605)
+++ trunk/postgis/mvt.c	2017-08-29 19:09:43 UTC (rev 15606)
@@ -700,7 +700,9 @@
 	if (lwgeom_out == NULL || lwgeom_is_empty(lwgeom_out))
 		return NULL;
 
-	lwgeom_out = lwgeom_make_valid(lwgeom_out);
+	if (lwgeom_out->type != POINTTYPE && lwgeom_out->type != MULTIPOINTTYPE)
+		lwgeom_out = lwgeom_make_valid(lwgeom_out);
+
 	if (lwgeom_out->type == POLYGONTYPE ||
 		lwgeom_out->type == MULTIPOLYGONTYPE) {
 		lwgeom_force_clockwise(lwgeom_out);



More information about the postgis-tickets mailing list