Browse Source

r.neighbors: Fix r59669; weights= implies non-integer result

git-svn-id: https://svn.osgeo.org/grass/grass/branches/releasebranch_7_0@59678 15284696-431f-4ddb-bdfa-cd5b030d7da7
Markus Neteler 11 years ago
parent
commit
3ca8b8e246
1 changed files with 2 additions and 2 deletions
  1. 2 2
      raster/r.neighbors/main.c

+ 2 - 2
raster/r.neighbors/main.c

@@ -323,8 +323,8 @@ int main(int argc, char *argv[])
 	    : 0;
 	out->buf = Rast_allocate_d_buf();
 	out->fd = Rast_open_new(output_name,
-				menu[method].is_int ? CELL_TYPE : DCELL_TYPE);
-    /* TODO: method=mode should propagate its type */
+				(menu[method].is_int && !out->method_fn_w) ? CELL_TYPE : DCELL_TYPE);
+	/* TODO: method=mode should propagate its type */
 
 	/* get title, initialize the category and stat info */
 	if (parm.title->answer)