From: Paul Ramsey Date: Mon, 10 Jun 2019 20:25:59 +0000 (+0000) Subject: Remove unused function gserialized_copy X-Git-Tag: 3.0.0alpha3~73 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e3eb88efb6d8090cd4085b52952e634b046ff975;p=postgis Remove unused function gserialized_copy git-svn-id: http://svn.osgeo.org/postgis/trunk@17484 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/liblwgeom/g_serialized.c b/liblwgeom/g_serialized.c index 6b9877c11..d49157ccf 100644 --- a/liblwgeom/g_serialized.c +++ b/liblwgeom/g_serialized.c @@ -138,15 +138,6 @@ inline static int gserialized_cmp_srid(const GSERIALIZED *s1, const GSERIALIZED ) ? 0 : 1; } -GSERIALIZED* gserialized_copy(const GSERIALIZED *g) -{ - GSERIALIZED *g_out = NULL; - assert(g); - g_out = (GSERIALIZED*)lwalloc(SIZE_GET(g->size)); - memcpy((uint8_t*)g_out,(uint8_t*)g,SIZE_GET(g->size)); - return g_out; -} - static size_t gserialized_is_empty_recurse(const uint8_t *p, int *isempty); static size_t gserialized_is_empty_recurse(const uint8_t *p, int *isempty) { diff --git a/liblwgeom/liblwgeom.h.in b/liblwgeom/liblwgeom.h.in index 4ef150e76..9cbbdfae5 100644 --- a/liblwgeom/liblwgeom.h.in +++ b/liblwgeom/liblwgeom.h.in @@ -1744,11 +1744,6 @@ extern void deparse_hex(uint8_t str, char *result); */ extern char* gserialized_to_string(const GSERIALIZED *g); -/** -* Return a copy of the input serialized geometry. -*/ -extern GSERIALIZED* gserialized_copy(const GSERIALIZED *g); - /** * Check that coordinates of LWGEOM are all within the geodetic range (-180, -90, 180, 90) */