[geos-devel] [GEOS] #721: WKBReader fails reading little-endian MULTIPOINT M EWKB
GEOS
geos-trac at osgeo.org
Sun Mar 22 04:58:55 PDT 2015
#721: WKBReader fails reading little-endian MULTIPOINT M EWKB
----------------------+-----------------------------------------------------
Reporter: benmorel | Owner: geos-devel@…
Type: defect | Status: new
Priority: blocker | Milestone: 3.4.3
Component: Default | Version: svn-trunk
Severity: Critical | Keywords:
----------------------+-----------------------------------------------------
This seemed related to my previous ticket #707 at first glance, but I
double-checked this is EWKB and not ISO WKB, so it should be handled
properly by libGEOS.
Test code (executed with PHP bindings):
$reader = new GeosWKBReader();
$reader->readHEX('0104000040020000000101000040000000000000f03f000000000000004000000000000008400101000040000000000000004000000000000008400000000000001040');
The reader fails with "ParseException: Unknown WKB type 0".
Although this is valid EWKB, as confirmed by PostGIS:
SELECT
ST_AsText(ST_GeomFromEWKB(DECODE('0104000040020000000101000040000000000000f03f000000000000004000000000000008400101000040000000000000004000000000000008400000000000001040',
'HEX')));
> MULTIPOINT M (1 2 3,2 3 4)
--
Ticket URL: <http://trac.osgeo.org/geos/ticket/721>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).
More information about the geos-devel
mailing list