From 5a2a4acad3434db582122d86c11b4351426ba887 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bj=C3=B6rn=20Harrtell?= Date: Sun, 5 Mar 2017 11:58:54 +0000 Subject: [PATCH] Clone LWGEOM in aggregation step References #3720 git-svn-id: http://svn.osgeo.org/postgis/trunk@15321 b70326c6-7e19-0410-871a-916f4a2858ee --- postgis/geobuf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/postgis/geobuf.c b/postgis/geobuf.c index b0c4b3242..e9f9aa1b2 100644 --- a/postgis/geobuf.c +++ b/postgis/geobuf.c @@ -540,7 +540,7 @@ void geobuf_agg_transfn(struct geobuf_agg_context *ctx) if (!datum) lwerror("geobuf_agg_transfn: geometry column cannot be null"); gs = (GSERIALIZED *) PG_DETOAST_DATUM(datum); - lwgeom = lwgeom_from_gserialized(gs); + lwgeom = lwgeom_clone_deep(lwgeom_from_gserialized(gs)); feature = encode_feature(ctx); -- 2.50.1