Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/make Move initialization of savederr to the block wh...



details:   https://anonhg.NetBSD.org/src/rev/d8a511706364
branches:  trunk
changeset: 336902:d8a511706364
user:      sjg <sjg%NetBSD.org@localhost>
date:      Thu Mar 26 22:20:42 2015 +0000

description:
Move initialization of savederr to the block where it is used
to avoid spurious warning from gcc 5

diffstat:

 usr.bin/make/main.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (43 lines):

diff -r 94eaef73b4ec -r d8a511706364 usr.bin/make/main.c
--- a/usr.bin/make/main.c       Thu Mar 26 22:04:38 2015 +0000
+++ b/usr.bin/make/main.c       Thu Mar 26 22:20:42 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.231 2014/09/09 06:18:17 dholland Exp $      */
+/*     $NetBSD: main.c,v 1.232 2015/03/26 22:20:42 sjg Exp $   */
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,7 +69,7 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: main.c,v 1.231 2014/09/09 06:18:17 dholland Exp $";
+static char rcsid[] = "$NetBSD: main.c,v 1.232 2015/03/26 22:20:42 sjg 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.231 2014/09/09 06:18:17 dholland Exp $");
+__RCSID("$NetBSD: main.c,v 1.232 2015/03/26 22:20:42 sjg Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -1493,7 +1493,6 @@
 
 
     *errnum = NULL;
-    savederr = 0;
 
     if (!shellName)
        Shell_Init();
@@ -1547,6 +1546,7 @@
         */
        (void)close(fds[1]);
 
+       savederr = 0;
        Buf_Init(&buf, 0);
 
        do {



Home | Main Index | Thread Index | Old Index