[Gdal-dev] adding lines and polygons in gdal-1.3.2

humarco marco.hugentobler at karto.baug.ethz.ch
Wed May 10 07:46:35 EDT 2006


Dear gdal devs,

I have a problem with gdal-1.3.2 when adding lines and polygons to (shapefile) 
layers. When i try to add lines to a line layer, ogr crashes. With polygons 
no crash happens, but the polygons are not writen to the layer. It works ok 
for points. And it also used to work with gdal-1.2.6 (the last version i 
upgraded from). Is this a bug or false usage from me? 
The crash happens another part of the code, so there may be a memory problem. 
The platform i'm using is ubuntu linux, breezy badger. The code to add 
features looks like this: 

if(ogrLayer->CreateFeature(feature)!=OGRERR_NONE)
  {
    QgsLogger::warning("Writing of the feature failed");
    returnValue = false;
  }
  ++numberFeatures;
  delete feature;
  ogrLayer->SyncToDisk();

thanks,
Marco







More information about the Gdal-dev mailing list