]> granicus.if.org Git - postgis/commitdiff
address_standardizer fix initialization from incompatible pointer type for PostgreSQL...
authorRegina Obe <lr@pcorp.us>
Wed, 6 Sep 2017 05:39:59 +0000 (05:39 +0000)
committerRegina Obe <lr@pcorp.us>
Wed, 6 Sep 2017 05:39:59 +0000 (05:39 +0000)
Closes #3830

git-svn-id: http://svn.osgeo.org/postgis/trunk@15636 b70326c6-7e19-0410-871a-916f4a2858ee

extensions/address_standardizer/std_pg_hash.c

index b4a760d99f603039ebd43b5ac0e584b80493b157..68377141c6dffb6d47db72f07bbbfabf8155dde9 100644 (file)
@@ -14,7 +14,7 @@
 /* standardizer headers */
 #undef DEBUG
 //#define DEBUG 1
-
+#include "../../postgis_config.h"
 #include "pagc_api.h"
 #include "pagc_std_api.h"
 #include "std_pg_hash.h"
@@ -96,7 +96,13 @@ static void StdCacheInit(MemoryContext context);
 static void StdCacheReset(MemoryContext context);
 static void StdCacheDelete(MemoryContext context);
 static bool StdCacheIsEmpty(MemoryContext context);
+
+#if POSTGIS_PGSQL_VERSION >= 96
+static void StdCacheStats(MemoryContext context, int level, bool print, MemoryContextCounters *totals);
+#else
 static void StdCacheStats(MemoryContext context, int level);
+#endif
+
 #ifdef MEMORY_CONTEXT_CHECKING
 static void StdCacheCheck(MemoryContext context);
 #endif
@@ -180,19 +186,28 @@ StdCacheIsEmpty(MemoryContext context)
 }
 
 
+#if POSTGIS_PGSQL_VERSION >= 96
+static void
+StdCacheStats(MemoryContext context, int level, bool print, MemoryContextCounters *totals)
+{
+    // another required function
+    fprintf(stderr, "%s: STANDARDIZER context\n", context->name);
+}
+#else
 static void
 StdCacheStats(MemoryContext context, int level)
 {
     // another required function
     fprintf(stderr, "%s: STANDARDIZER context\n", context->name);
 }
+#endif
 
 
 #ifdef MEMORY_CONTEXT_CHECKING
 static void
 StdCacheCheck(MemoryContext context)
 {
-    // NOP - another reuired function
+    // NOP - another required function
 }
 #endif