Changeset 14381

Show
Ignore:
Timestamp:
05/06/08 11:49:44 (2 months ago)
Author:
warmerdam
Message:

make parser more permissive (#2348)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/1.5/gdal/frmts/usgsdem/usgsdemdataset.cpp

    r12593 r14381  
    323323        fscanf(InDem, "%d", &i); 
    324324        fscanf(InDem, "%d", &j); 
    325         if ((i!=1)||(j!=1))                   // File OK? 
     325        if ((i!=1)||(j!=1 && j != 0)) // File OK? 
    326326        { 
    327327            VSIFSeek(InDem, 893, 0);    // Undocumented Format (39109h1.dem) 
     
    541541        return FALSE; 
    542542 
    543     if( !EQUALN((const char *) poOpenInfo->pabyHeader+150, "     1",6) ) 
     543    if( !EQUALN((const char *) poOpenInfo->pabyHeader+150, "     1",6)  
     544        && !EQUALN((const char *) poOpenInfo->pabyHeader+150, "     4",6)) 
    544545        return FALSE; 
    545546