[GRASS-SVN] r68869 - grass/branches/releasebranch_7_2/raster/r.what
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Jul 6 12:19:32 PDT 2016
Author: neteler
Date: 2016-07-06 12:19:32 -0700 (Wed, 06 Jul 2016)
New Revision: 68869
Modified:
grass/branches/releasebranch_7_2/raster/r.what/main.c
Log:
r.what: do not shadow same variable name (gcc flag -Wshadow) (trunk, r68868)
Modified: grass/branches/releasebranch_7_2/raster/r.what/main.c
===================================================================
--- grass/branches/releasebranch_7_2/raster/r.what/main.c 2016-07-06 19:19:09 UTC (rev 68868)
+++ grass/branches/releasebranch_7_2/raster/r.what/main.c 2016-07-06 19:19:32 UTC (rev 68869)
@@ -51,7 +51,7 @@
{
int i, j;
int nfiles;
- char *name;
+ char *oname;
int fd[NFILES];
struct Categories cats[NFILES];
struct Cell_head window;
@@ -164,10 +164,10 @@
if (G_parser(argc, argv))
exit(EXIT_FAILURE);
- name = opt.output->answer;
- if (name != NULL && strcmp(name, "-") != 0) {
- if (NULL == freopen(name, "w", stdout)) {
- G_fatal_error(_("Unable to open file <%s> for writing"), name);
+ oname = opt.output->answer;
+ if (oname != NULL && strcmp(oname, "-") != 0) {
+ if (NULL == freopen(oname, "w", stdout)) {
+ G_fatal_error(_("Unable to open file <%s> for writing"), oname);
}
}
More information about the grass-commit
mailing list