[GRASS-SVN] r74471 - grass/trunk/lib/proj

svn_grass at osgeo.org svn_grass at osgeo.org
Sun May 5 13:34:04 PDT 2019


Author: mmetz
Date: 2019-05-05 13:34:03 -0700 (Sun, 05 May 2019)
New Revision: 74471

Modified:
   grass/trunk/lib/proj/do_proj.c
Log:
libproj: code clean-up

Modified: grass/trunk/lib/proj/do_proj.c
===================================================================
--- grass/trunk/lib/proj/do_proj.c	2019-05-05 20:27:33 UTC (rev 74470)
+++ grass/trunk/lib/proj/do_proj.c	2019-05-05 20:34:03 UTC (rev 74471)
@@ -25,7 +25,6 @@
 /* a couple defines to simplify reading the function */
 #define MULTIPLY_LOOP(x,y,c,m) \
 do {\
-   int i; \
    for (i = 0; i < c; ++i) {\
        x[i] *= m; \
        y[i] *= m; \
@@ -34,7 +33,6 @@
 
 #define DIVIDE_LOOP(x,y,c,m) \
 do {\
-   int i; \
    for (i = 0; i < c; ++i) {\
        x[i] /= m; \
        y[i] /= m; \
@@ -723,9 +721,9 @@
 		    const struct pj_info *info_in, const struct pj_info *info_out)
 {
     int ok;
+    int i;
     int has_h = 1;
 #ifdef HAVE_PROJ_H
-    int i;
     struct pj_info info_trans;
     PJ_COORD c;
 
@@ -818,8 +816,6 @@
     METERS_out = info_out->meters;
 
     if (h == NULL) {
-	int i;
-
 	h = G_malloc(sizeof *h * count);
 	/* they say memset is only guaranteed for chars ;-( */
 	for (i = 0; i < count; ++i)



More information about the grass-commit mailing list