[GRASS-SVN] r70746 - grass/branches/releasebranch_7_2/raster/r.what
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat Mar 11 17:39:21 PST 2017
Author: annakrat
Date: 2017-03-11 17:39:21 -0800 (Sat, 11 Mar 2017)
New Revision: 70746
Modified:
grass/branches/releasebranch_7_2/raster/r.what/main.c
Log:
r.what: fix segfault when using -r and outside of region (merge from trunk, r70745)
Modified: grass/branches/releasebranch_7_2/raster/r.what/main.c
===================================================================
--- grass/branches/releasebranch_7_2/raster/r.what/main.c 2017-03-12 01:37:38 UTC (rev 70745)
+++ grass/branches/releasebranch_7_2/raster/r.what/main.c 2017-03-12 01:39:21 UTC (rev 70746)
@@ -415,10 +415,10 @@
}
if (flg.color->answer) {
if (out_type[i] == CELL_TYPE)
- Rast_get_c_color(&cell[i][cache[point].col],
+ Rast_get_c_color(&(cache[point].value[i]),
&red, &green, &blue, &ncolor[i]);
else
- Rast_get_d_color(&dcell[i][cache[point].col],
+ Rast_get_d_color(&(cache[point].dvalue[i]),
&red, &green, &blue, &ncolor[i]);
sprintf(cache[point].clr_buf[i], "%03d:%03d:%03d", red,
More information about the grass-commit
mailing list