From owner-cvs-all Thu Mar 7 12:51:26 2002 Delivered-To: cvs-all@freebsd.org Received: from storm.FreeBSD.org.uk (storm.FreeBSD.org.uk [194.242.139.170]) by hub.freebsd.org (Postfix) with ESMTP id 9AF0837B41E; Thu, 7 Mar 2002 12:51:05 -0800 (PST) Received: (from uucp@localhost) by storm.FreeBSD.org.uk (8.11.6/8.11.6) with UUCP id g27Kosk61432; Thu, 7 Mar 2002 20:50:54 GMT (envelope-from mark@grimreaper.grondar.za) Received: from grimreaper (localhost [127.0.0.1]) by grimreaper.grondar.org (8.12.2/8.12.2) with ESMTP id g27KnKRV073901; Thu, 7 Mar 2002 20:49:20 GMT (envelope-from mark@grimreaper.grondar.za) Message-Id: <200203072049.g27KnKRV073901@grimreaper.grondar.org> To: Alfred Perlstein Cc: Mike Silbersack , cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/usr.bin/rwall rwall.c References: <20020307203324.GH26621@elvis.mu.org> In-Reply-To: <20020307203324.GH26621@elvis.mu.org> ; from Alfred Perlstein "Thu, 07 Mar 2002 12:33:24 PST." Date: Thu, 07 Mar 2002 20:49:20 +0000 From: Mark Murray Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > > I believe I've asked this before, but I haven't heard a good answer: > > > > What benefit do the WARNS changes have? > > > > I'd understand the need for "strcpy -> strlcpy changes" or "snprintf > > changes", but I don't see what good the WARNS changes are having. Is this > > documented somewhere? > > I'm not sure about it being documented however my point of view is that > it gives us code that can be compiled with a high number of compiler > diagnostics turned on to prevent and aid in preventing future mistakes. What Alfred said. The more you can get the compiler to help you, the less stupid mistakes you make. When calling foreign functions, mixing modules, getting creative with data structures, etc, the amount of work that you can unload to the compiler by turning on this level of warning can save boatloads of work. I've had _many_ bugs pointed out to me by turning on maximum warnings. My opinion is that for shared code, this amount of proactive help is so wise as to be (almost) compulsory. M -- o Mark Murray \_ O.\_ Warning: this .sig is umop ap!sdn To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message