[gdal-dev] PGeo driver errors
Ryk DeYoe
rdeyoe at clarksville.com
Mon Jan 14 17:30:27 EST 2008
-----Original Message-----
From: Frank Warmerdam [mailto:warmerdam at pobox.com]
Sent: Monday, January 14, 2008 2:45 PM
To: Ryk DeYoe
Cc: gdal-dev at lists.osgeo.org
Subject: Re: [gdal-dev] PGeo driver errors
Ryk DeYoe wrote:
> I'm using the PGeo driver to try to read some ESRI geodatabases to feed
> Mapserver. I'm running Ubuntu Edgy. The standard Ubuntu gdal didn't have
> PGeo compiled in so I've compiled gdal 1.3.1 (to match the Ubuntu libs)
with
> PGeo. I've created the necessary ODBC connections to the mdb files. I
also
> have the standard mdb-tools package installed. I'm getting a "stack
> smashing detected" error when trying to read the layers from the mdb file.
> I think I've narrowed it down to reading the SRTEXT field from the
> GDB_SpatialRefs table. If i put dummy values in the field, it will read
the
> tables and give me layers but of course, the SRS is completely wrong.
I've
> compiled gdal with stack protection turned off and then it just
segfaults...
...
> I have an sql.log file tracing the odbc calls. Looks ok until it starts
> selecting the srtext values. I'm not sure but the buffer length seems to
be
> set to 511 where my srtext string is 542 in length. Could this be the
> problem? And where can I increase this value?....in the ODBC source?...or
> in gdal? (I've downloaded the odbc source just in case i have to rebuild)
...
> Everything else with gdal seems to run great. Shape files aren't a
problem
> but our GIS department doesn't update the shape files anymore....they work
> in the geodatabases exclusively now. Our geotiff aerial photos look very
> nice and the gdaltindex stitched them together pretty simply. I've been
> trying to find the place to set the buffer size but not being a programmer
> has me at a disadvantage.
Ryk,
This sounds like an old but with the CPL ODBC code. I suspect you need this
patch:
http://trac.osgeo.org/gdal/changeset/12531
Presumably there is more info available in the associated bug ticket:
http://trac.osgeo.org/gdal/ticket/1902
Best regards,
--
---------------------------------------+------------------------------------
--
I set the clouds in motion - turn up | Frank Warmerdam,
warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | President OSGeo, http://osgeo.org
Thanks Frank, but there's no happiness there. I'm still getting the same
error. Just for fun, I grabbed the 1.5.0 source and saw that patch in
cpl_odbc.cpp also. Compiled the 1.5.0 source and ran ogrinfo from the
gdal/apps directory and it's doing the same thing. The sql.log file stops
at the same place, selecting srtext on the first record (there are 12
layers):
------- tail sql.log (ran with 1.5.0 ogrinfo) ---------
[ODBC][2064][SQLExecDirect.c][236]
Entry:
Statement = 0x8088bc0
SQL = [SELECT srtext FROM GDB_SpatialRefs WHERE srid
= 1][length = 49 (SQL_NTS)]
[ODBC][2064][SQLExecDirect.c][499]
Exit:[SQL_SUCCESS]
[ODBC][2064][SQLNumResultCols.c][149]
Entry:
Statement = 0x8088bc0
Column Count = 0xbff6ef10
[ODBC][2064][SQLNumResultCols.c][234]
Exit:[SQL_SUCCESS]
Count = 0xbff6ef10 -> 1
[ODBC][2064][SQLDescribeCol.c][231]
Entry:
Statement = 0x8088bc0
Column Number = 1
Column Name = 0xbff6eda8
Buffer Length = 256
Name Length = 0xbff6eda6
Data Type = 0x80879a0
Column Size = 0x8087a58
Decimal Digits = 0x80880f0
Nullable = 0x8087b68
[ODBC][2064][SQLDescribeCol.c][474]
Exit:[SQL_SUCCESS]
Column Name = Indicator = -18719
Data Type = 0x80879a0 -> -1
Column Size = 0x8087a58 -> 0
Decimal Digits = 0x80880f0 -> 0
Nullable = 0x8087b68 -> 1
[ODBC][2064][SQLFetch.c][158]
Entry:
Statement = 0x8088bc0
[ODBC][2064][SQLFetch.c][340]
Exit:[SQL_SUCCESS]
[ODBC][2064][SQLGetData.c][230]
Entry:
Statement = 0x8088bc0
Column Number = 1
Target Type = 1 SQL_CHAR
Buffer Length = 511
Target Value = 0xbff6ecc8
StrLen Or Ind = 0xbff6ecac
[ODBC][2064][SQLGetData.c][494]
Exit:[SQL_SUCCESS]
Buffer =
[PROJCS["NAD_1983_StatePlane_Tennessee_FIPS_4100_Feet",GEOGCS["GCS_North_Ame
rican_1983",DA
TUM["D_North_American_1983",SPHEROID["G]
Strlen Or Ind = 0xbff6ecac -> 12
--------- *SPLAT! -----------------------------------------
More information about the gdal-dev
mailing list