From owner-svn-src-all@FreeBSD.ORG Sun Dec 18 16:33:33 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 64E811065670; Sun, 18 Dec 2011 16:33:33 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id 245DD8FC13; Sun, 18 Dec 2011 16:33:33 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:1c1b:9549:1b4:20d] (unknown [IPv6:2001:7b8:3a7:0:1c1b:9549:1b4:20d]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 64FC05C37; Sun, 18 Dec 2011 17:33:32 +0100 (CET) Message-ID: <4EEE15DB.6060604@FreeBSD.org> Date: Sun, 18 Dec 2011 17:33:31 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:9.0) Gecko/20111214 Thunderbird/9.0 MIME-Version: 1.0 To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201112172232.pBHMW1Bd079555@svn.freebsd.org> <4EED18B5.8000907@FreeBSD.org> <20111218013905.GA20867@zim.MIT.EDU> <20111218014144.GB20867@zim.MIT.EDU> In-Reply-To: <20111218014144.GB20867@zim.MIT.EDU> X-Enigmail-Version: 1.3.4 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Subject: Re: svn commit: r228668 - head/usr.bin/netstat X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Dec 2011 16:33:33 -0000 On 2011-12-18 02:41, David Schultz wrote: ... > Sorry, one more: In less(1), you cast away a bunch of const qualifiers > to fix some warnings, but that seems like a step in the wrong > direction. The warnings were complaining about genuinely bad code. > Disabling the warnings with casts doesn't make less(1) any better; > instead, it guarantees that nobody will ever fix the code. Yes, I did it purposefully this way. Constifying the whole program would have much more impact, and increase the probability of a bug sneaking in. That said, if anybody knows if the less maintainer (Mark Nudelman?) is responsive, I have no problem doing a proper const poisoning, and submitting it to him for review. > Perhaps the larger question is whether it makes sense to fix non-bugs > in contributed code at all. What do we get out of it? Maybe if the > contrib software is poorly maintained we'll find a bunch of real bugs > that won't be addressed upstream. Otherwise, the diffs are only creating > headaches for whoever imports the next version. The criterion I use for fixing warnings is rather simple: if the contrib software is compiled with -Werror, then apparently we (or at least some of us :) are interested in the warnings, and they should be fixed. If we are not interested in the warnings, we should just turn off -Werror. Of course, if warnings point to a real problem, and upstream for the contrib software still exists, we should strive for submitting them, and getting them back through imports. That can take a very long time, however, and meanwhile the warnings still block building world with -Werror. Thus, in some cases, it is better to fix them now, and just merge the fixes during import. If upstream accepts our fixes verbatim, they should not conflict anyway.