Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/make make(1): remove mistyped extern variable



details:   https://anonhg.NetBSD.org/src/rev/7ecdeb090b8c
branches:  trunk
changeset: 942042:7ecdeb090b8c
user:      rillig <rillig%NetBSD.org@localhost>
date:      Wed Nov 04 13:27:00 2020 +0000

description:
make(1): remove mistyped extern variable

Robust programs don't have extern variable declarations in .c files, as
that risks incomatible definitions that are not detected by the compiler
and invoke undefined behavior.  Make make a little more robust.

diffstat:

 usr.bin/make/meta.c |  3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diffs (17 lines):

diff -r 4e67cf1828e9 -r 7ecdeb090b8c usr.bin/make/meta.c
--- a/usr.bin/make/meta.c       Wed Nov 04 13:22:15 2020 +0000
+++ b/usr.bin/make/meta.c       Wed Nov 04 13:27:00 2020 +0000
@@ -1,4 +1,4 @@
-/*      $NetBSD: meta.c,v 1.136 2020/10/31 12:04:24 rillig Exp $ */
+/*      $NetBSD: meta.c,v 1.137 2020/11/04 13:27:00 rillig Exp $ */
 
 /*
  * Implement 'meta' mode.
@@ -80,7 +80,6 @@
 static Boolean metaSilent = FALSE;     /* if we have a .meta be SILENT */
 
 extern Boolean forceJobs;
-extern Boolean comatMake;
 extern char    **environ;
 
 #define        MAKE_META_PREFIX        ".MAKE.META.PREFIX"



Home | Main Index | Thread Index | Old Index