From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6586 invoked by alias); 8 Oct 2004 16:17:19 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 6569 invoked from network); 8 Oct 2004 16:17:17 -0000 Received: from unknown (HELO boden.synopsys.com) (198.182.44.79) by sourceware.org with SMTP; 8 Oct 2004 16:17:17 -0000 Received: from mother.synopsys.com (mother.synopsys.com [146.225.100.171]) by boden.synopsys.com (Postfix) with ESMTP id B540ADBC3; Fri, 8 Oct 2004 09:16:45 -0700 (PDT) Received: from piper.synopsys.com (localhost [127.0.0.1]) by mother.synopsys.com (8.9.1/8.9.1) with ESMTP id JAA14653; Fri, 8 Oct 2004 09:17:15 -0700 (PDT) Received: (from jbuck@localhost) by piper.synopsys.com (8.11.6/8.11.6) id i98GHEt01732; Fri, 8 Oct 2004 09:17:14 -0700 X-Authentication-Warning: piper.synopsys.com: jbuck set sender to Joe.Buck@synopsys.com using -f Date: Fri, 08 Oct 2004 17:20:00 -0000 From: Joe Buck To: Nick Ing-Simmons Cc: jamie@shareable.org, gcc@gcc.gnu.org, "'Morten Welinder'" , Dave Korn Subject: Re: signed vs unsigned pointer warning Message-ID: <20041008091714.A1695@synopsys.com> References: <20040922161751.B4F6A1422D53@darter.rentec.com><20040926192142.GA29842@mail.shareable.org> <20040926192142.GA29842@mail.shareable.org> <20041008130623.9516.4@llama.elixent.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20041008130623.9516.4@llama.elixent.com>; from nick@ing-simmons.net on Fri, Oct 08, 2004 at 02:06:23PM +0100 X-SW-Source: 2004-10/txt/msg00359.txt.bz2 On Fri, Oct 08, 2004 at 02:06:23PM +0100, Nick Ing-Simmons wrote: > >This is a real typical bug. Just recently a bug was found in > >curl-library, quite a popular little library, which calls > >isspace(char). The bug was missed for a long time, as it is only > >triggered with characters with the MSB set, which do not occur often > >in HTTP headers. > > I am reasnably sure that on old SunOS4 systems passing signed char > to isxxx() was normal and worked. The lookup tables where defined > in such a way that 128 or so entries before the normal table replicated > the 2nd half. Why can't an implementation define isxxx(c) to return something like table_lookup[(unsigned)(c)] ?