[GRASS5] r.texture segfault
Markus Neteler
neteler at itc.it
Wed Jun 29 11:30:15 EDT 2005
Hi,
we found a bug in r.texture which I'm unable to resolve.
To reproduce it in Spearfish, run
g.region rast=spot.image -p
r.rescale spot.image to=0,255 out=spot.resc
r.texture in=spot.resc -v pref=spot.image size=10 distance=5
Segmentation fault
I found with the debugger following
(gdb) r in=spot.resc -v pref=spot.image size=10 distance=5
Starting program: /hardmnt/thuille0/ssi/software/cvsgrass61/dist.i686-pc-linux-gnu/bin/r.texture in=spot.resc -v pref=spot.image size=10 distance=5
Reading the raster map...done
0%
Program received signal SIGSEGV, Segmentation fault.
0x08049574 in h_measure (grays=0x87798e0, rows=10, cols=10, t_m=12, t_d=5)
at h_measure.c:124
124 while (tone[y] != grays[row][col + d])
(gdb) bt
#0 0x08049574 in h_measure (grays=0x87798e0, rows=10, cols=10, t_m=12, t_d=5)
at h_measure.c:124
#1 0x0804d657 in main (argc=6, argv=0xbfe19214) at main.c:309
The 'ddd' tells me that tone[y] is unavailable. Probably y get's
too large and then the crash occurs.
How to fix this?
Thanks
Markus
More information about the grass-dev
mailing list