problem with --enable-cassert)
- Fixed bbox cache handling bugs
- Fixed geom_accum(NULL, NULL) segfault
+ - Initial support for postgresql 8.2
PostGIS 1.0.5
2005/11/25
*/
++nelems;
if ( nelems == 1 || ! array ) {
- nbytes = ARR_OVERHEAD(1)+INTALIGN(geom->size);
+ nbytes = ARR_OVERHEAD_NONULLS(1)+INTALIGN(geom->size);
#ifdef PGIS_DEBUG
elog(NOTICE, "geom_accum: adding %p (nelems=%d; nbytes=%d)",
geom, nelems, nbytes);
#if USE_VERSION > 72
result->elemtype = oid;
+#endif
+#if USE_VERSION > 81
+ result->dataoffset = 0;
#endif
memcpy(ARR_DIMS(result), &nelems, sizeof(int));
memcpy(ARR_LBOUND(result), &lbs, sizeof(int));
#ifdef PGIS_DEBUG
elog(NOTICE, " array is %d-bytes in size, %d w/out header",
- array->size, array->size-ARR_OVERHEAD(ARR_NDIM(array)));
+ array->size, array->size-ARR_OVERHEAD_NONULLS(ARR_NDIM(array)));
#endif
#define PG_NARGS() (fcinfo->nargs)
#endif
+#if USE_VERSION < 82
+#define ARR_OVERHEAD_NONULLS(x) ARR_OVERHEAD((x))
+#endif
+
void *pg_alloc(size_t size);
void *pg_realloc(void *ptr, size_t size);
void pg_free(void *ptr);