From: Regina Obe Date: Wed, 20 Dec 2017 16:18:57 +0000 (+0000) Subject: if def out GetPJHashEntry for >-96 when we are using PostgreSQL built-in context... X-Git-Tag: 2.5.0alpha~273 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=682779d3cc84f4ae11ef9aa7a7d6053a05552f9f;p=postgis if def out GetPJHashEntry for >-96 when we are using PostgreSQL built-in context. We don't use it cause it returns projection, not the HashEntry grrh. Take it out to quiet travis whining about how we define a function we are not using. References #3946 git-svn-id: http://svn.osgeo.org/postgis/trunk@16168 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/libpgcommon/lwgeom_transform.c b/libpgcommon/lwgeom_transform.c index 894e104d8..a8db28eda 100644 --- a/libpgcommon/lwgeom_transform.c +++ b/libpgcommon/lwgeom_transform.c @@ -76,7 +76,10 @@ uint32 mcxt_ptr_hash(const void *key, Size keysize); static HTAB *CreatePJHash(void); static void AddPJHashEntry(MemoryContext mcxt, projPJ projection); +#if POSTGIS_PGSQL_VERSION < 96 +/** see note on function def why this is useless **/ static projPJ GetPJHashEntry(MemoryContext mcxt); +#endif static void DeletePJHashEntry(MemoryContext mcxt); /* Internal Cache API */ @@ -265,6 +268,11 @@ static void AddPJHashEntry(MemoryContext mcxt, projPJ projection) } } +/** TODO: May reconsider changing this to return entry as name implies + * For now it's useless when we are using built-in context cause + * we need the entry for cleanup + * */ +#if POSTGIS_PGSQL_VERSION < 96 static projPJ GetPJHashEntry(MemoryContext mcxt) { void **key; @@ -278,7 +286,7 @@ static projPJ GetPJHashEntry(MemoryContext mcxt) return he->projection; } - +#endif static void DeletePJHashEntry(MemoryContext mcxt) {