From owner-freebsd-bugs@FreeBSD.ORG Wed Jan 26 17:11:51 2005 Return-Path: Delivered-To: freebsd-bugs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 573FD16A4CE for ; Wed, 26 Jan 2005 17:11:51 +0000 (GMT) Received: from gw.celabo.org (gw.celabo.org [208.42.49.153]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6FCB143D1F for ; Wed, 26 Jan 2005 17:11:50 +0000 (GMT) (envelope-from nectar@celabo.org) Received: from lum.celabo.org (lum.celabo.org [10.0.1.107]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "lum.celabo.org", Issuer "celabo.org CA" (verified OK)) by gw.celabo.org (Postfix) with ESMTP id B320A3E2C23; Wed, 26 Jan 2005 11:11:45 -0600 (CST) Received: by lum.celabo.org (Postfix, from userid 1001) id 6405C597F7B; Wed, 26 Jan 2005 11:11:45 -0600 (CST) Date: Wed, 26 Jan 2005 11:11:45 -0600 From: "Jacques A. Vidrine" To: Stefan Farfeleder Message-ID: <20050126171145.GG1441@lum.celabo.org> Mail-Followup-To: "Jacques A. Vidrine" , Stefan Farfeleder , keramida@ceid.upatras.gr, freebsd-bugs@FreeBSD.org, sos22@cantab.net References: <20050126101332.GI21084@wombat.fafoe.narf.at> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050126101332.GI21084@wombat.fafoe.narf.at> X-Url: http://www.celabo.org/ User-Agent: Mutt/1.5.6i cc: keramida@ceid.upatras.gr cc: freebsd-bugs@FreeBSD.org cc: sos22@cantab.net Subject: Re: Dubious #define in include/pwd.h X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Jan 2005 17:11:51 -0000 On Wed, Jan 26, 2005 at 11:13:34AM +0100, Stefan Farfeleder wrote: > Giorgos Keramidas wrote: > > On 2005-01-25 21:46, Steven Smith wrote: > > > I was messing around with sparse, the static checker used sometimes > > > by Linux kernel people, and I (or rather, it) came upon the line > > > > > > #define _PW_VERSION_MASK '0xF0' > > > > > > in /usr/src/include/pwd.h. I can't immediately see any use for this; > > > '\xf0' would probably be more useful. > > > > If this is used as a mask for 'unsigned char' values, why would it make > > any difference? Aren't they both going to be implicitly converted to > > the right typep anyway? > > No, '0xF0' is a multi-character-constant, its value is implementation-defined > and that's probably not what Jacques (CC'ed) intended. It probably > should be just 0xF0 (without the quotes) or '\xF0'. A grep through the > src tree didn't show any usage of this macro though. Er, yes, that's a typo (^_^;) Fortunately, that define is not used. I'll correct it. Is there a PR associated with this? Cheers, -- Jacques A Vidrine / NTT/Verio nectar@celabo.org / jvidrine@verio.net / nectar@FreeBSD.org