[GRASS-dev] [grass-code I] r.in.xyz: a segfault with
rez at touchofmadness.com
Thu Oct 11 00:36:35 EDT 2007
On Wed, 2007-10-10 at 00:40 +0100, Glynn Clements wrote:
> grass-dev at grass.itc.it wrote:
> > code I item #507, was opened at 2007-10-09 17:11
> > Status: Open
> > Priority: 3
> > Submitted By: Maciej Sieczka (msieczka)
> > Assigned to: Hamish Bowman (hamish)
> > Summary: r.in.xyz: a segfault with particular dataset
> > Issue type: module bug
> > Issue status: None
> > GRASS version: CVS HEAD
> > GRASS component: raster
> > Operating system: Linux
> > Operating system version: Ubuntu Dapper 64bit
> > GRASS CVS checkout date, if applies (YYMMDD): 071009
> > Initial Comment:
> > r.in.xyz has been segfaulting with a particular dataset. It's quite
> > big (23 MB bzipped) and I don't know how to provide it but let me
> > know if ther's a need+way to.
> I suggest:
> 1. Changing G_incr_void_ptr() to use size_t.
> 2. Changing G_raster_size() to return size_t (that's what sizeof
Committed to CVS.
> returns, which is the reason for size_t's existence).
> 3. Casting "cols" to a size_t, so that the index calculation is
> performed at size_t width.
> If size_t isn't enough to index the array (i.e. you have a 32-bit
> size_t on a platform which can calloc() more than 4GiB), you lose
73, de Brad KB8UYR/6 <rez touchofmadness com>
More information about the grass-dev