From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26727 invoked by alias); 19 Apr 2011 14:33:50 -0000 Received: (qmail 26717 invoked by uid 22791); 19 Apr 2011 14:33:49 -0000 X-SWARE-Spam-Status: No, hits=1.0 required=5.0 tests=AWL,BAYES_00,KAM_STOCKTIP,RCVD_IN_DNSWL_NONE,TW_BJ X-Spam-Check-By: sourceware.org Received: from mail-out.m-online.net (HELO mail-out.m-online.net) (212.18.0.9) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 19 Apr 2011 14:33:35 +0000 Received: from frontend1.mail.m-online.net (unknown [192.168.8.180]) by mail-out.m-online.net (Postfix) with ESMTP id CD8711C009F7; Tue, 19 Apr 2011 16:33:32 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.8.164]) by mail.m-online.net (Postfix) with ESMTP id 38FFE1C000F3; Tue, 19 Apr 2011 16:33:32 +0200 (CEST) Received: from mail.mnet-online.de ([192.168.8.180]) by localhost (dynscan1.mail.m-online.net [192.168.8.164]) (amavisd-new, port 10024) with ESMTP id epsHJd03AGTj; Tue, 19 Apr 2011 16:33:32 +0200 (CEST) Received: from igel.home (ppp-88-217-114-91.dynamic.mnet-online.de [88.217.114.91]) by mail.mnet-online.de (Postfix) with ESMTP; Tue, 19 Apr 2011 16:33:31 +0200 (CEST) Received: by igel.home (Postfix, from userid 501) id 09E42CA2A0; Tue, 19 Apr 2011 16:33:29 +0200 (CEST) From: Andreas Schwab To: "Pierre Muller" Cc: "'Pedro Alves'" , Subject: Re: [RFA] ARI fix: avoid assignment in if clause in xcoffread.c References: <000901cbfe97$9ed7f120$dc87d360$@muller@ics-cnrs.unistra.fr> <201104191501.53552.pedro@codesourcery.com> <36908.1941120841$1303222432@news.gmane.org> X-Yow: I hope the ``Eurythmics'' practice birth control... Date: Tue, 19 Apr 2011 14:33:00 -0000 In-Reply-To: <36908.1941120841$1303222432@news.gmane.org> (Pierre Muller's message of "Tue, 19 Apr 2011 16:13:22 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2011-04/txt/msg00324.txt.bz2 "Pierre Muller" writes: > + pp = (char *) strchr (name, ':'); The cast is useless, though, so I checked this in as obvious. Andreas. 2011-04-19 Andreas Schwab * xcoffread.c (process_xcoff_symbol): Remove useless cast. (scan_xcoff_symtab): Likewise. --- xcoffread.c.~1.86.~ 2011-04-19 16:25:37.000000000 +0200 +++ xcoffread.c 2011-04-19 16:26:41.000000000 +0200 @@ -1588,7 +1588,7 @@ process_xcoff_symbol (struct coff_symbol if (*name == ':') return NULL; - pp = (char *) strchr (name, ':'); + pp = strchr (name, ':'); if (pp == NULL) return NULL; @@ -2623,7 +2623,7 @@ scan_xcoff_symtab (struct objfile *objfi swap_sym (&symbol, &main_aux[0], &namestring, &sraw_symbol, &ssymnum, objfile); - p = (char *) strchr (namestring, ':'); + p = strchr (namestring, ':'); if (!p) continue; /* Not a debugging symbol. */ -- Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."