Hi.

A recent post to the GCC mailing listed a couple of possible bugs in make.

http://gcc.gnu.org/ml/gcc-bugs/2000-02/msg00455.html

Attatched is a patch fixing (I believe) said problems. In job.c, there
are extra ';' charcters at the end of an if statement, and in main.c, the
added parenthesis make if statment clearer. I've rebuilt my make (3.78.91),
and it passed my testsuite with no failures.

--- ./job.c_orig        Mon Feb  7 08:13:48 2000
+++ ./job.c     Sun Feb 20 10:25:44 2000
@@ -2465,9 +2465,9 @@
 
     slow_flag = strcmp((s1 ? s1 : ""), (s2 ? s2 : ""));
 
-    if (s1);
+    if (s1)
       free(s1);
-    if (s2);
+    if (s2)
       free(s2);
   }
   if (slow_flag)
--- ./main.c_orig       Sun Feb 20 10:27:59 2000
+++ ./main.c    Sun Feb 20 10:30:06 2000
@@ -2683,7 +2683,7 @@
        print_version ();
 
       /* Wait for children to die.  */
-      for (err = status != 0; job_slots_used > 0; err = 0)
+      for (err = (status != 0); job_slots_used > 0; err = 0)
        reap_children (1, err);
 
       /* Let the remote job module clean up its state.  */

Apply at your discretion.

Thanks.

Art Haas

Reply via email to