aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Stallman <rms@gnu.org>1992-09-03 07:15:21 +0000
committerRichard Stallman <rms@gnu.org>1992-09-03 07:15:21 +0000
commit058d85217a2d130f17be352e66807aab44609cfc (patch)
treec6d0e4539153edcd9ff8064bb1e24d98b1853442
parent9233f8ce4800fd62f1bd8f87624c02b2436ffd01 (diff)
downloadgcc-058d85217a2d130f17be352e66807aab44609cfc.zip
gcc-058d85217a2d130f17be352e66807aab44609cfc.tar.gz
gcc-058d85217a2d130f17be352e66807aab44609cfc.tar.bz2
(main): Use new loop var J to avoid conflict with I.
From-SVN: r2043
-rw-r--r--gcc/gcc.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/gcc/gcc.c b/gcc/gcc.c
index 6977414..b78990a 100644
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -3197,6 +3197,7 @@ main (argc, argv)
char **argv;
{
register int i;
+ int j;
int value;
int error_count = 0;
int linker_was_run = 0;
@@ -3371,17 +3372,19 @@ main (argc, argv)
input_suffix = "";
len = 0;
- for (i = 0; i < sizeof cp->spec / sizeof cp->spec[0] && cp->spec[i]; i++)
- len += strlen (cp->spec[i]);
+ for (j = 0; j < sizeof cp->spec / sizeof cp->spec[0]; j++)
+ if (cp->spec[j])
+ len += strlen (cp->spec[j]);
p = (char *) xmalloc (len + 1);
len = 0;
- for (i = 0; i < sizeof cp->spec / sizeof cp->spec[0] && cp->spec[i]; i++)
- {
- strcpy (p + len, cp->spec[i]);
- len += strlen (cp->spec[i]);
- }
+ for (j = 0; j < sizeof cp->spec / sizeof cp->spec[0]; j++)
+ if (cp->spec[j])
+ {
+ strcpy (p + len, cp->spec[j]);
+ len += strlen (cp->spec[j]);
+ }
value = do_spec (p);
free (p);