Le lundi 23 août 2010 05:28:17, Stephen Woodbridge a écrit : > Even, > > It seems the adding: > > #include <cpl_conv.h> > > resolves the segv issue.
Strange, I think there's no particular good reason why it worked with GTiff and not VRT. I assume you compile on a 64bit platform and that without header the return type was assumed to be of integer type, thus leading to pointer trucation. > > I would recommend changing the example in: > > http://www.gdal.org/gdal_tutorial.html > > To include that in the section "Reading Raster Data" because the example > C code uses CPLMalloc(). It would also be very helpful to add: > > ... > CPLFree(pafScanline); Done _______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev