From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/7543 Path: news.gmane.org!not-for-mail From: Szabolcs Nagy Newsgroups: gmane.linux.lib.musl.general Subject: Re: Pending patches & other changes Date: Tue, 28 Apr 2015 15:55:06 +0200 Message-ID: <20150428135505.GC11625@port70.net> References: <20150428034820.GA28803@brightrain.aerifal.cx> <20150428094320.GA11625@port70.net> <20150428134647.GN17573@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1430229324 17953 80.91.229.3 (28 Apr 2015 13:55:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 28 Apr 2015 13:55:24 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-7556-gllmg-musl=m.gmane.org@lists.openwall.com Tue Apr 28 15:55:24 2015 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1Yn5yq-0007Yd-3f for gllmg-musl@m.gmane.org; Tue, 28 Apr 2015 15:55:20 +0200 Original-Received: (qmail 32682 invoked by uid 550); 28 Apr 2015 13:55:18 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 32661 invoked from network); 28 Apr 2015 13:55:17 -0000 Mail-Followup-To: musl@lists.openwall.com Content-Disposition: inline In-Reply-To: <20150428134647.GN17573@brightrain.aerifal.cx> User-Agent: Mutt/1.5.23 (2014-03-12) Xref: news.gmane.org gmane.linux.lib.musl.general:7543 Archived-At: * Rich Felker [2015-04-28 09:46:47 -0400]: > On Tue, Apr 28, 2015 at 11:43:21AM +0200, Szabolcs Nagy wrote: > > i forgot to do this one in elf.h: > > > > -#define SHF_EXCLUDE (1 << 31) > > +#define SHF_EXCLUDE (1U << 31) > > > > (there is no other invalid <<31) > > This was discussed quite a bit on libc-alpha (glibc list) and it seems > the consensus there is that changing the type to unsigned is > potentially dangerous and it would be better to use (-0x7fffffff-1) or > perhaps ((1<<30) * -2) if it's more clear. What do you think? > the glibc bikeshed ended with florian saying "I thought some more about this, and have changed my opinion completely. Making the constant unsigned is less risky than making it negative because of potential sign extension issues." https://sourceware.org/ml/libc-alpha/2015-04/msg00264.html and they committed the original 1U<<31 patch today