|
RE: Errors in dgnread.cpp: msg#00115gis.gdal.devel
Frank, Here is the dgn file. Its not too big, but forgive me if I shouldn't have sent this to the list. It's a pretty simple dgn file just contours and text. The error happens on the first element the (tcb). Steve. -----Original Message----- From: gdal-dev-admin@xxxxxxxxxxxxxxxxx [mailto:gdal-dev-admin@xxxxxxxxxxxxxxxxx] On Behalf Of Frank Warmerdam Sent: Saturday, September 20, 2003 7:40 PM To: gdal-dev@xxxxxxxxxxxxxxxxx Cc: dgnlib Subject: Re: [Gdal-dev] Errors in dgnread.cpp Steve Brooks wrote: > I have found two fatal errors in dgnread.cpp the first one will cause > a > crash > when there appears to be attributes on the tcb which inside the 'if' > psElement->attr_bytes gets setup as a negative number which causes the > CPLMalloc to crash. If you would like a copy of the dgn file let me > know. My fix was not to go inside the if( psElement->properties & > DGNPF_ATTRIBUTES ) if the element is a tcb. > > The next change was causing OGRLayer::GetFeature > to not return any features. When the DGN Index was being built the > offset was being truncated to an invalid offest by the (unsigned char) > cast. > > My envionment is Windows XP, Microsoft Visual Studio.Net 2003. Steve, I would appreciate a file to demonstrate the first problem. The second is a very serious bug introduced in a fit of (apparently improper) type casting fixes, and apparently breaks any random (rather than sequential) index based element reads. I have committed the fix for both but would still like to understand the first issue better. I am cc:ing the dgnlib list since it mostly effects people there, and I will issue a new dgnlib within a couple days once I am happy with the fixes. Best regards, -- ---------------------------------------+-------------------------------- ---------------------------------------+------ I set the clouds in motion - turn up | Frank Warmerdam, warmerdam@xxxxxxxxx light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent _______________________________________________ Gdal-dev mailing list Gdal-dev@xxxxxxxxxxxxxxxxx http://remotesensing.org/mailman/listinfo/gdal-dev
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: gdal_translation interpolation: 00115, Frank Warmerdam |
|---|---|
| Next by Date: | Geosoft Grid eXchange Format and Projection support: 00115, N. Farah |
| Previous by Thread: | Re: Errors in dgnread.cppi: 00115, Frank Warmerdam |
| Next by Thread: | s-57 to vrml elevation map?: 00115, Thorsten=20R=F6llich |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |