From 210b45e1e90ee0508ae8f3b7b6b87cc11a6e88ef Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bj=C3=B6rn=20Harrtell?= Date: Fri, 10 Mar 2017 20:17:32 +0000 Subject: [PATCH] Add missing guard when libprotobuf-c is not available git-svn-id: http://svn.osgeo.org/postgis/trunk@15325 b70326c6-7e19-0410-871a-916f4a2858ee --- postgis/lwgeom_out_mvt.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/postgis/lwgeom_out_mvt.c b/postgis/lwgeom_out_mvt.c index f97da9815..b797773c8 100644 --- a/postgis/lwgeom_out_mvt.c +++ b/postgis/lwgeom_out_mvt.c @@ -41,6 +41,10 @@ PG_FUNCTION_INFO_V1(ST_AsMVTGeom); Datum ST_AsMVTGeom(PG_FUNCTION_ARGS) { +#ifndef HAVE_LIBPROTOBUF + lwerror("Missing libprotobuf-c"); + PG_RETURN_NULL(); +#else LWGEOM *lwgeom_in, *lwgeom_out; GSERIALIZED *geom_in, *geom_out; GBOX *bounds; @@ -62,6 +66,7 @@ Datum ST_AsMVTGeom(PG_FUNCTION_ARGS) lwgeom_free(lwgeom_out); PG_FREE_IF_COPY(geom_in, 0); PG_RETURN_POINTER(geom_out); +#endif } /** -- 2.50.1