From owner-svn-src-all@freebsd.org Thu Jan 25 14:42:53 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 17693EDC03B; Thu, 25 Jan 2018 14:42:53 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail110.syd.optusnet.com.au (mail110.syd.optusnet.com.au [211.29.132.97]) by mx1.freebsd.org (Postfix) with ESMTP id 86F1D7FE4C; Thu, 25 Jan 2018 14:42:51 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from [192.168.0.102] (c110-21-101-228.carlnfd1.nsw.optusnet.com.au [110.21.101.228]) by mail110.syd.optusnet.com.au (Postfix) with ESMTPS id 762F0107648; Fri, 26 Jan 2018 01:42:46 +1100 (AEDT) Date: Fri, 26 Jan 2018 01:42:45 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: "Pedro F. Giffuni" cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r328340 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs In-Reply-To: <201801241644.w0OGivto028334@repo.freebsd.org> Message-ID: <20180126010213.X1950@besplex.bde.org> References: <201801241644.w0OGivto028334@repo.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.2 cv=YbvN30Zf c=1 sm=1 tr=0 a=PalzARQSbocsUSjMRkwAPg==:117 a=PalzARQSbocsUSjMRkwAPg==:17 a=kj9zAlcOel0A:10 a=3RMtp7UOCSDtmHLZNVwA:9 a=CjuIK1q_8ugA:10 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 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: Thu, 25 Jan 2018 14:42:53 -0000 On Wed, 24 Jan 2018, Pedro F. Giffuni wrote: > Log: > Revert r327781, r328093, r328056: > ufs|ext2fs: Revert uses of mallocarray(9). > > These aren't really useful: drop them. > Variable unsigning will be brought again later. Variable "unsigning" (that is, adding unsign extension bugs) is even more negatively useful than mallocarray(), so should not be brought back. Unsigning variables used _only_ for array sizes and element counts doesn't cause any new problems (and fixes warnings about converting from signed to unsigned when calling malloc*()), but it is a lot of work to check that they aren't used for other things where their signedness matters (perhaps differences or loops that count down to -1 instead of 0). Unsigned variables also break checking for overflow in expressions by compiling with -ftrapv. Bruce