[postgis-devel] invalid memory alloc request size

strk at refractions.net strk at refractions.net
Thu Jun 9 08:18:33 PDT 2005


# select isvalid('GEOMETRYCOLLECTION EMPTY'::geometry);
 isvalid
---------
 t

# select multi('GEOMETRYCOLLECTION EMPTY'::geometry);
       multi
--------------------
 010700000000000000

# select postgis_full_version();
                                   postgis_full_version                         
-------------------------------------------------------------------------------------------
 POSTGIS="1.1.0CVS" PROJ="Rel. 4.4.8, 3 May 2004" USE_STATS DBPROC="0.3.1" RELPROC="0.3.1"


I resemble this bug, found this log entry:

2005-03-18 13:36  strk

        * lwgeom/: liblwgeom.c, liblwgeom.h, lwcollection.c, lwgeom.c,
          lwgeom.h, lwgeom_api.c, lwgeom_box3d.c, lwgeom_ogc.c,
          lwgeom_pg.c, lwgeom_transform.c, lwline.c, lwpoint.c, lwpoly.c,
          ptarray.c: Big API cleanup.  Bug fix in box3d computation for
          collections containing empty elements.

Does
	SELECT 'GEOMETRYCOLLECTION EMPTY'::geometry;
give you the same problem ? (box3d should be computed anyway)

--strk;


On Thu, Jun 09, 2005 at 04:22:21PM +0200, Markus Schaber wrote:
> Hello,
> 
> Markus Schaber wrote:
> 
> > The following happens with PostGIS 1.0.0 as well as a 1.1CVS, on both
> > i386 and AMD-64.
> > 
> > lwgeom11=# select isvalid('GEOMETRYCOLLECTION EMPTY'::geometry);
> > ERROR:  invalid memory alloc request size 0
> 
> While we are at it:
> 
> lwgeom11=# select multi('GEOMETRYCOLLECTION EMPTY'::geometry);
> ERROR:  invalid memory alloc request size 0
> 
> I know that it may be nonsense to call multi() on an empty collection,
> but this was where it had bitten us as we called multi() on the result
> of an intersection() operation.
> 
> Markus
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel



More information about the postgis-devel mailing list