]> granicus.if.org Git - postgis/commitdiff
if def out GetPJHashEntry for >-96 when we are using PostgreSQL built-in context...
authorRegina Obe <lr@pcorp.us>
Wed, 20 Dec 2017 16:18:57 +0000 (16:18 +0000)
committerRegina Obe <lr@pcorp.us>
Wed, 20 Dec 2017 16:18:57 +0000 (16:18 +0000)
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

libpgcommon/lwgeom_transform.c

index 894e104d8ebebb56b984697a9954017be1ebac95..a8db28eda51905bc3be244658bc5c6268b74cbe0 100644 (file)
@@ -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)
 {