Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/make appease gcc -Wuninitialized



details:   https://anonhg.NetBSD.org/src/rev/755901f3a597
branches:  trunk
changeset: 581672:755901f3a597
user:      lukem <lukem%NetBSD.org@localhost>
date:      Fri Jun 03 16:15:46 2005 +0000

description:
appease gcc -Wuninitialized

diffstat:

 usr.bin/make/main.c |  9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diffs (44 lines):

diff -r 20eae37e27ff -r 755901f3a597 usr.bin/make/main.c
--- a/usr.bin/make/main.c       Fri Jun 03 16:13:33 2005 +0000
+++ b/usr.bin/make/main.c       Fri Jun 03 16:15:46 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.107 2005/06/01 17:17:34 sjg Exp $   */
+/*     $NetBSD: main.c,v 1.108 2005/06/03 16:15:46 lukem Exp $ */
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,7 +69,7 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: main.c,v 1.107 2005/06/01 17:17:34 sjg Exp $";
+static char rcsid[] = "$NetBSD: main.c,v 1.108 2005/06/03 16:15:46 lukem Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
@@ -81,7 +81,7 @@
 #if 0
 static char sccsid[] = "@(#)main.c     8.3 (Berkeley) 3/19/94";
 #else
-__RCSID("$NetBSD: main.c,v 1.107 2005/06/01 17:17:34 sjg Exp $");
+__RCSID("$NetBSD: main.c,v 1.108 2005/06/03 16:15:46 lukem Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -225,6 +225,7 @@
        getopt_def = OPTFLAGS;
 rearg: 
        inOption = FALSE;
+       optscan = NULL;
        while(argc > 1) {
                char *getopt_spec;
                if(!inOption)
@@ -262,6 +263,8 @@
                                argvalue = argv[2];
                                arginc = 2;
                        }
+               } else {
+                       argvalue = NULL; 
                }
                switch(c) {
                case '\0':



Home | Main Index | Thread Index | Old Index