]> sjero.net Git - wget/commitdiff
[svn] In for loops with empty body, put the ";" on a separate line to silence
authorhniksic <devnull@localhost>
Thu, 7 Jul 2005 01:08:52 +0000 (18:08 -0700)
committerhniksic <devnull@localhost>
Thu, 7 Jul 2005 01:08:52 +0000 (18:08 -0700)
a warning from DMC.

src/ftp-basic.c
src/ftp-ls.c
src/init.c
src/snprintf.c
src/utils.c

index b992d19cadb59aa7e51f9fcddbadef4490a57598..753566aeb862d5c3b4d6ecb3d18ebbfdb8060746 100644 (file)
@@ -526,7 +526,8 @@ ftp_pasv (int csock, ip_address *addr, int *port)
     }
   /* Parse the request.  */
   s = respline;
-  for (s += 4; *s && !ISDIGIT (*s); s++);
+  for (s += 4; *s && !ISDIGIT (*s); s++)
+    ;
   if (!*s)
     return FTPINVPASV;
   for (i = 0; i < 6; i++)
@@ -594,7 +595,8 @@ ftp_lpsv (int csock, ip_address *addr, int *port)
 
   /* Parse the response.  */
   s = respline;
-  for (s += 4; *s && !ISDIGIT (*s); s++);
+  for (s += 4; *s && !ISDIGIT (*s); s++)
+    ;
   if (!*s)
     return FTPINVPASV;
 
index 93bdf79f53421a0bc68c0be094985c30b37b6ac4..ce17f450b86c12a745c73ab83507f5d112a44fab 100644 (file)
@@ -642,7 +642,8 @@ ftp_parse_vms_ls (const char *file)
       tok = strtok(line, " ");
       if (tok == NULL) tok = line;
       DEBUGP(("file name: '%s'\n", tok));
-      for (p = tok ; *p && *p != ';' ; p++);
+      for (p = tok ; *p && *p != ';' ; p++)
+       ;
       if (*p == ';') *p = '\0';
       p   = tok + strlen(tok) - 4;
       if (!strcmp(p, ".DIR")) *p = '\0';
@@ -724,10 +725,12 @@ ftp_parse_vms_ls (const char *file)
       min = sec = 0;
       p = tok;
       hour = atoi (p);
-      for (; *p && *p != ':'; ++p);
+      for (; *p && *p != ':'; ++p)
+       ;
       if (*p)
        min = atoi (++p);
-      for (; *p && *p != ':'; ++p);
+      for (; *p && *p != ':'; ++p)
+       ;
       if (*p)
        sec = atoi (++p);
 
index faffc44c4f1db7e8f963ad114c89fcaeea373969..d2e41a946005dc3dcea64c951d720eced2699673 100644 (file)
@@ -1389,7 +1389,8 @@ check_user_specified_header (const char *s)
 {
   const char *p;
 
-  for (p = s; *p && *p != ':' && !ISSPACE (*p); p++);
+  for (p = s; *p && *p != ':' && !ISSPACE (*p); p++)
+    ;
   /* The header MUST contain `:' preceded by at least one
      non-whitespace character.  */
   if (*p != ':' || p == s)
index b8e28f54fea84fbd6603e27c6eb13d17235ce28d..a68350766db0540d4c2f0ece8078606e2a2d279d 100644 (file)
@@ -485,7 +485,8 @@ static int fmtstr (char *buffer, size_t *currlen, size_t maxlen,
   else
     /* When precision is specified, don't read VALUE past precision. */
     /*strln = strnlen (value, max);*/
-    for (strln = 0; strln < max && value[strln]; ++strln);
+    for (strln = 0; strln < max && value[strln]; ++strln)
+      ;
   padlen = min - strln;
   if (padlen < 0) 
     padlen = 0;
index 6c94d7102425062161eafaec157145b4677584c9..29262c12e0a97ad91bd1f713e24c1e94ccb296b2 100644 (file)
@@ -670,9 +670,11 @@ bool
 frontcmp (const char *s1, const char *s2)
 {
   if (!opt.ignore_case)
-    for (; *s1 && *s2 && (*s1 == *s2); ++s1, ++s2);
+    for (; *s1 && *s2 && (*s1 == *s2); ++s1, ++s2)
+      ;
   else
-    for (; *s1 && *s2 && (TOLOWER (*s1) == TOLOWER (*s2)); ++s1, ++s2);
+    for (; *s1 && *s2 && (TOLOWER (*s1) == TOLOWER (*s2)); ++s1, ++s2)
+      ;
   return *s1 == '\0';
 }
 
@@ -1084,9 +1086,11 @@ merge_vecs (char **v1, char **v2)
       return v1;
     }
   /* Count v1.  */
-  for (i = 0; v1[i]; i++);
+  for (i = 0; v1[i]; i++)
+    ;
   /* Count v2.  */
-  for (j = 0; v2[j]; j++);
+  for (j = 0; v2[j]; j++)
+    ;
   /* Reallocate v1.  */
   v1 = xrealloc (v1, (i + j + 1) * sizeof (char **));
   memcpy (v1 + i, v2, (j + 1) * sizeof (char *));