From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1092 invoked by alias); 12 Apr 2010 18:45:53 -0000 Received: (qmail 1081 invoked by uid 22791); 12 Apr 2010 18:45:52 -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; Mon, 12 Apr 2010 18:45:44 +0000 Received: from vapier.localnet (localhost [127.0.0.1]) by smtp.gentoo.org (Postfix) with ESMTP id E01BF1B40CF; Mon, 12 Apr 2010 18:45:42 +0000 (UTC) From: Mike Frysinger To: Joel Brobecker Subject: Re: [PATCH] sim: tweak signed to unsigned local vars Date: Mon, 12 Apr 2010 18:45:00 -0000 User-Agent: KMail/1.13.1 (Linux/2.6.33.2; KDE/4.4.1; x86_64; ; ) Cc: gdb-patches@sourceware.org References: <1270936677-26654-1-git-send-email-vapier@gentoo.org> <20100412152413.GV19194@adacore.com> In-Reply-To: <20100412152413.GV19194@adacore.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart18697928.iicJ2zraON"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <201004121444.58803.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/msg00381.txt.bz2 --nextPart18697928.iicJ2zraON Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-length: 728 On Monday 12 April 2010 11:24:13 Joel Brobecker wrote: > > @@ -583,7 +583,7 @@ hw_add_range_array_property (struct hw *me, > >=20 > > * sizeof (unsigned_cell)); > >=20=20=20=20 > > unsigned_cell *cells =3D hw_zalloc (me, sizeof_cells); > > unsigned_cell *cell; > >=20 > > - int i; > > + unsigned i; >=20 > I am not sure about this one either. Can you try changing the type > of parameter nr_ranges to int? It looks like the only usage of this > function is in hw-tree, and the variable used is actually an int... the relevant funcs involved here seem like they should all be converted to= =20 unsigned. in the event of an error, they abort, and only ever return unsig= ned=20 values. i'll go that route. -mike --nextPart18697928.iicJ2zraON 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) iQIcBAABAgAGBQJLw2oqAAoJEEFjO5/oN/WBxYgQAL+4Rkt7fQCu+iVRTY99obxW 03h/QKhL953CgvL8l9Lkym2U6EgmP/+7Z6PH6vggM1bC1cZbzspssgqosztP9AFe 8HxbMiFFezq23nnsK8Q9r34n+9vEAhompF+pXZjkNDEqilOodlbctu4qy/u7BcbN bP2FerEtGqfD5D5rsgNPiMwiP/zrApMUREZ9BXP6KSViq1GJo3faZVh5JtJyM/Gf CvpT5Y76Uv5uBbyAXvJ9f66tyKWITXLSwiADfaDYOuP8DVReKMLegzSlvO32KiN8 aOe2j2NhWL+RB0zrvAEfKJacAuPWQq44Jt/otPzJMItmyQ3vQnXvVG5WsCv//Jkr 2OYhg+KrMRMoIxDZXXr/wzljy8Czoh3CFyR89YxmOP8nHMKDRt8/apuZr5WoLwHP qsR/hzRR5iOPdbagdQs0K1JDTlHdK+4LH3ozelGR3Y+eRB2gJ+hkrjx5HuA4DqSK shU9E5fRiHgQGPTmCdLip76Q9N0BsfdF269d1PYPJA/zANp7WAopankv0UwlK1AV 3hpR0ei9AKljyFn9QQghBJwA42xwxIVseDKfYkSaw8HpDflnN2xNuBwRQi2nmrkC DgrYD+eEhZ5uDprV4tpce34kkHZQKL84czK5QgYQP3rfRTQoyK5fBzbq2DTEpItS Pulei36XR6IhIJpUhip/ =VmSs -----END PGP SIGNATURE----- --nextPart18697928.iicJ2zraON--