From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31158 invoked by alias); 10 Apr 2010 21:25:16 -0000 Received: (qmail 31143 invoked by uid 22791); 10 Apr 2010 21:25:15 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from smtp.gentoo.org (HELO smtp.gentoo.org) (140.211.166.183) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 10 Apr 2010 21:25:11 +0000 Received: from vapier.localnet (localhost [127.0.0.1]) by smtp.gentoo.org (Postfix) with ESMTP id 9110C1B401E for ; Sat, 10 Apr 2010 21:25:09 +0000 (UTC) From: Mike Frysinger To: gdb-patches@sourceware.org Subject: Re: [patch] sim: constify sim_fpu_print_status Date: Sat, 10 Apr 2010 21:25:00 -0000 User-Agent: KMail/1.13.1 (Linux/2.6.33.2; KDE/4.4.1; x86_64; ; ) References: <201004101629.28634.vapier@gentoo.org> In-Reply-To: <201004101629.28634.vapier@gentoo.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart4449139.veTGJBX3mX"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <201004101724.50225.vapier@gentoo.org> X-IsSubscribed: yes 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: 2010-04/txt/msg00310.txt.bz2 --nextPart4449139.veTGJBX3mX Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-length: 1274 On Saturday 10 April 2010 16:29:28 Mike Frysinger wrote: > I've committed the following patch as obvious. The local "prefix" variab= le > is only assigned const strings, and only passed to printf() functions, so > add "const" to avoid gcc warnings: > common/sim-fpu.c: In function 'sim_fpu_print_status': > common/sim-fpu.c:2508: warning: initialization discards qualifiers from > pointer target type > common/sim-fpu.c:2566: warning: assignment discards qualifiers from point= er > target type blah, this takes it a little out of the "obvious" range, but i forgot to=20 include this hunk. hopefully it doesnt cause problems :/. 2010-04-10 Mike Frysinger * sim-fpu.c (sim_fpu_print_func): Add const markings to format buffer. RCS file: /cvs/src/src/sim/common/sim-fpu.h,v retrieving revision 1.15 diff -u -p -r1.15 sim-fpu.h --- sim/common/sim-fpu.h 1 Jan 2010 10:03:27 -0000 1.15 +++ sim/common/sim-fpu.h 10 Apr 2010 21:22:23 -0000 @@ -404,7 +404,7 @@ extern const sim_fpu sim_fpu_max64; =20 /* For debugging */ =20 -typedef void sim_fpu_print_func (void *, char *, ...); +typedef void sim_fpu_print_func (void *, const char *, ...); =20 /* Print a sim_fpu with full precision. */ INLINE_SIM_FPU (void) sim_fpu_print_fpu (const sim_fpu *f, --nextPart4449139.veTGJBX3mX Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. Content-length: 836 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (GNU/Linux) iQIcBAABAgAGBQJLwOyiAAoJEEFjO5/oN/WBL+8P/1ckk1iBIVx6eLCjzuyBv7ZZ Ip10zenca57JkOBuNBgbdA5aoxYtSIml5JcRTfQGvQHN5HBwSEgHhPMxdbPbnpSJ 3JeZm5tI7wJH8YUqlcWtfqYDjqKJ7Uk7ydjhWp29sZa9zm1n0c8MWfzdvPSxFv2A TBAjA7ipUeCGy0V2nSdT7O0wLw1D1S3rFfU5IY0AsDbAK7TDqkLTZ40Y3ZW9AQTY Sm307BFtBkbg2EJr+4PkyXx4LR8pE/HNLFFaoBtmVG1kZl36mFAvQvxTefssFR5f xXIzP21LTUCVihO5DhADwiP3afcJMErwSJi8fRf9Dx0tODIorxAaSm6Jbhcj/efL /3f2jOZr7oOs+p2z8dMYdfDi206gQUdsPChCcG2Rz9HvuUQmJ6SzttqoSUeM8gcK nJvo5Yd4O4ow21ULsmxODovDlEar+5k1YYjLLk59R3+BbxmYPVNgJ9oQnQxdBrij GL7yNYS+efC1cNtMKb4RwkPeonaeoHtboCJr6t/K7Wwgxa276W6SCpU96gonPUnU bjit8uQd8D900TGYoHsFIoQ83uBgpg6COY2oDZ/ir9bdMcUYKv/gezeGC2t1+O19 qfcZqjF4ybdE3qXiKLss5V25rwcF7pUfWbq+pzfxbzUz9LyhjTlb46VjU0luJfNs NxPDt793sCupH5vyjuNK =7EjK -----END PGP SIGNATURE----- --nextPart4449139.veTGJBX3mX--