Opened 10 years ago

Closed 10 years ago

#3974 closed enhancement (fixed)

Case insensitive ERS parsing

Reported by: rprinceley Owned by: warmerdam
Priority: normal Milestone: 1.8.1
Component: GDAL_Raster Version: svn-trunk
Severity: normal Keywords: ERS
Cc: gaopeng

Description

We have a few user submitted ERS files that are all lowercase (except quoted strings). GDAL fails parsing such files, but these are supported by ERDAS applications (and older versions of ArcGIS).

Attachments (1)

header.ers (786 bytes) - added by rprinceley 10 years ago.

Download all attachments as: .zip

Change History (4)

comment:1 Changed 10 years ago by warmerdam

Keywords: ERS added
Status: newassigned

I don't immediately see obvious case sensitivity issues in the gdal/frmts/ers. Could you attach a header that demonstrates the problem?

Changed 10 years ago by rprinceley

Attachment: header.ers added

comment:2 Changed 10 years ago by rprinceley

Frank,

The problem is in ERSHdrNode::ParseChildren?. CPLString (based on std::string) is case sensitive, CPLString::find() ends up calling memcmp() to compare strings.

comment:3 Changed 10 years ago by warmerdam

Milestone: 1.8.1
Resolution: fixed
Status: assignedclosed

I have corrected the problem in trunk (r21813,r21814), 1.8 (r21815) and 1.8-esri (r21817).

Testing added in trunk (r21818).

Note: See TracTickets for help on using tickets.