[postgis-users] PostGIS, 64 bit Solaris, Invalide memory alloc message using force_collection

Michael Fuhr mike at fuhr.org
Fri Feb 3 11:53:55 PST 2006


On Fri, Feb 03, 2006 at 10:52:54AM +0100, strk at refractions.net wrote:
> Thanks guys, I've changed the typedef
> to use the POSIX uint32_t type.
> Tests welcome (in HEAD)

Unfortunately Solaris 9 doesn't have stdint.h :-(  It does, however,
make exact-width integer types available via inttypes.h, which is
another standard-defined way of getting them (inttypes.h is supposed
to include stdint.h; even though Solaris 9 doesn't have stdint.h,
inttypes.h picks up the typedefs from elsewhere).  Hopefully there
aren't any systems that have stdint.h but not inttypes.h :-(

The loader also needs changing:

% grep 'typedef.*long' `find . -type f`
./loader/wkb.h:typedef unsigned long int uint32;
./loader/pgsql2shp.c:typedef unsigned long int uint32;
./loader/shpopen.c:typedef long       int32;
./lwgeom/wktparse.h:/*typedef unsigned long int4;*/

Fixing the loader typedefs then causes a printf() warning:

pgsql2shp.c:416: warning: long unsigned int format, different type arg (arg 2)

-- 
Michael Fuhr



More information about the postgis-users mailing list