From 058d85217a2d130f17be352e66807aab44609cfc Mon Sep 17 00:00:00 2001 From: Richard Stallman Date: Thu, 3 Sep 1992 07:15:21 +0000 Subject: [PATCH] (main): Use new loop var J to avoid conflict with I. From-SVN: r2043 --- gcc/gcc.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/gcc/gcc.c b/gcc/gcc.c index 6977414ea02..b78990a73f7 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); -- 2.30.2