From owner-cvs-src@FreeBSD.ORG Wed Sep 26 02:43:11 2007 Return-Path: Delivered-To: cvs-src@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A39FB16A420; Wed, 26 Sep 2007 02:43:11 +0000 (UTC) (envelope-from edwin@mavetju.org) Received: from mail5out.barnet.com.au (mail5.barnet.com.au [202.83.178.78]) by mx1.freebsd.org (Postfix) with ESMTP id 4CDBA13C45A; Wed, 26 Sep 2007 02:43:11 +0000 (UTC) (envelope-from edwin@mavetju.org) Received: by mail5out.barnet.com.au (Postfix, from userid 1001) id 4C3362219D61; Wed, 26 Sep 2007 12:43:10 +1000 (EST) X-Viruscan-Id: <46F9C73E0000970195FE6B@BarNet> Received: from mail5auth.barnet.com.au (mail5.barnet.com.au [202.83.178.78]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mail5.barnet.com.au (Postfix) with ESMTP id 13E7621B1101; Wed, 26 Sep 2007 12:43:10 +1000 (EST) Received: from k7.mavetju (k7.mavetju.org [10.251.1.18]) by mail5auth.barnet.com.au (Postfix) with ESMTP id B23E62219D35; Wed, 26 Sep 2007 12:43:09 +1000 (EST) Received: by k7.mavetju (Postfix, from userid 1001) id E73825D; Wed, 26 Sep 2007 12:43:11 +1000 (EST) Date: Wed, 26 Sep 2007 12:43:11 +1000 From: Edwin Groothuis To: Greg 'groggy' Lehey Message-ID: <20070926024311.GD1384@k7.mavetju> References: <200709252141.l8PLfMGv001982@repoman.freebsd.org> <20070926021827.GO91528@dereel.lemis.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20070926021827.GO91528@dereel.lemis.com> User-Agent: Mutt/1.4.2.3i Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/gnu/usr.bin/man/man man.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Sep 2007 02:43:11 -0000 On Wed, Sep 26, 2007 at 12:18:27PM +1000, Greg 'groggy' Lehey wrote: > On Tuesday, 25 September 2007 at 21:41:22 +0000, Edwin Groothuis wrote: > > edwin 2007-09-25 21:41:22 UTC > > > > FreeBSD src repository > > > > Modified files: > > gnu/usr.bin/man/man man.c > > Log: > > Fix possible uninitialized variable insert due to previous commit. > > > > Pointy hat to: me and my absence of -Wall in my CFLAGS. > > My recollection was that you accidentally removed -O from the flags, > and that optimization is needed for the compiler to recognize this > situation. Without CFLAGS in my /etc/make.conf (will give -O2 in the run) [/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man] root@k7>make clean man.o rm -f man.1 man man.o manpath.o glob.o man.1.gz man.1.cat.gz cc -O2 -fno-strict-aliasing -pipe -I/usr/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man/../lib -DHAVE_LIBZ=1 -I/usr/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man/../lib -DSTDC_HEADERS -DPOSIX -DHAS_TROFF -DDO_COMPRESS -DCATMODE=0644 -c man.c With CFLAGS=-Wall on the command line (will give -Wall in the run, but no -O2) [/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man] root@k7>CFLAGS=-Wall make clean man.o rm -f man.1 man man.o manpath.o glob.o man.1.gz man.1.cat.gz cc -Wall -I/usr/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man/../lib -DHAVE_LIBZ=1 -I/usr/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man/../lib -DSTDC_HEADERS -DPOSIX -DHAS_TROFF -DDO_COMPRESS -DCATMODE=0644 -c man.c With CFLAGS+=-Wall in my /etc/make.conf (will give -O2 and -Wall): [/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man] root@k7>make clean man.o rm -f man.1 man man.o manpath.o glob.o man.1.gz man.1.cat.gz cc -O2 -fno-strict-aliasing -pipe -Wall -I/usr/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man/../lib -DHAVE_LIBZ=1 -I/usr/home/edwin/cvs/freebsd/src-current/gnu/usr.bin/man/man/../lib -DSTDC_HEADERS -DPOSIX -DHAS_TROFF -DDO_COMPRESS -DCATMODE=0644 -c man.c man.c: In function `ultimate_source': man.c:878: warning: 'end' might be used uninitialized in this function You are right about needing -Wall *and* -O to get the warnings. Edwin -- Edwin Groothuis | Personal website: http://www.mavetju.org edwin@mavetju.org | Weblog: http://www.mavetju.org/weblog/