[GRASS-SVN] r70630 - grass/trunk/raster/r.terraflow

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Feb 19 15:24:27 PST 2017


Author: wenzeslaus
Date: 2017-02-19 15:24:26 -0800 (Sun, 19 Feb 2017)
New Revision: 70630

Modified:
   grass/trunk/raster/r.terraflow/stats.cpp
Log:
r.terraflow: compile with -Werror=format-security (fixes r70516, see r66561, #2773, #3280)

grass-daily 7.3.svn Ubuntu 16.04 and 16.10 use -Werror=format-security.


Modified: grass/trunk/raster/r.terraflow/stats.cpp
===================================================================
--- grass/trunk/raster/r.terraflow/stats.cpp	2017-02-19 21:55:23 UTC (rev 70629)
+++ grass/trunk/raster/r.terraflow/stats.cpp	2017-02-19 23:24:26 UTC (rev 70630)
@@ -88,7 +88,7 @@
 	G_debug(1, "file %s exists - renaming.\n", fname);
 	sprintf(buf, "%s.old", fname);
 	if(rename(fname, buf) != 0) {
-	  G_fatal_error(fname);
+	  G_fatal_error("%s", fname);
 	}
       }
     }
@@ -109,7 +109,7 @@
       G_debug(1, "file %s exists - renaming.\n", fname);
       sprintf(buf, "%s.old", fname);
       if(rename(fname, buf) != 0) {
-	G_fatal_error(fname);
+	G_fatal_error("%s", fname);
       }
       close(fd);
     }



More information about the grass-commit mailing list