From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) by sourceware.org (Postfix) with ESMTP id 2A0343853558 for ; Sun, 23 Oct 2022 13:47:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 2A0343853558 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gentoo.org Received: by smtp.gentoo.org (Postfix, from userid 559) id BB39B341084; Sun, 23 Oct 2022 13:47:16 +0000 (UTC) Date: Sun, 23 Oct 2022 18:17:50 +0545 From: Mike Frysinger To: Andrew Burgess Cc: gdb-patches@sourceware.org Subject: Re: [PATCH 5/5] sim/iq2000: silence pointer-sign warnings Message-ID: Mail-Followup-To: Andrew Burgess , gdb-patches@sourceware.org References: <89f7a81c43e4b9acf725de1668f7754692e6dd83.1665578246.git.aburgess@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="IUQUragEon+AR9lB" Content-Disposition: inline In-Reply-To: <89f7a81c43e4b9acf725de1668f7754692e6dd83.1665578246.git.aburgess@redhat.com> X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --IUQUragEon+AR9lB Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 12 Oct 2022 13:38, Andrew Burgess via Gdb-patches wrote: > When building the iq2000 simulator I see a few warnings like this: >=20 > /tmp/build/sim/../../src/sim/iq2000/iq2000.c: In function =E2=80=98fetc= h_str=E2=80=99: > /tmp/build/sim/../../src/sim/iq2000/iq2000.c:50:54: error: pointer targ= ets in passing argument 3 of =E2=80=98sim_read=E2=80=99 differ in signednes= s [-Werror=3Dpointer-sign] > 50 | sim_read (CPU_STATE (current_cpu), CPU2DATA(addr), buf, nr); > | ^~~ > | | > | char * >=20 > I've silenced these warnings by casting buf to 'unsigned char *'. > With this change I now see no warnings when compiling iq2000.c, so > I've removed the line from Makefile.in that disables -Werror. i left this warning in place so someone would fix it properly rather than just cast it away -mike --IUQUragEon+AR9lB Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEuQK1JxMl+JKsJRrUQWM7n+g39YEFAmNVNHIACgkQQWM7n+g3 9YGfWBAAp2QNb7Zwg67far+LJCl9gvIoCfAQWk5BS7uJTmkqRLpHCZIANSB/aDda L6vmSrmGD7T2OOa/1q//VbkP+yKJMwN3Wf2ZCZZF6b8ZoNPYTwTSscJikIY2Xb/Y baMX/pXM3fQsKKWFc5phnwSAXRL7eiDYcPzeFzT+R1EnoZunUp5PsCiSXs8S9Yzf TLAYyBSMtluR0Efb7H4bC+SkNkadJyJ1Jaay8TnQ9ZoEl87vID0UdNkvSmqMPbCB 9A0oMfozbJa8tXTmY1M3QH6qM2TLzNUZ6TANd+PCNsGn4K0l+6UZ9+PhkEok62KH gqB0/d71MFicS4YcomuUo6fmSdWt7UURGqKoFqDt8Qcc2iZUFdOAYJrLE/c/+DkW UXUOroWq3uPpYARaElUr4sbLLYk95VOnVlZpvRamMBI1R8M+aLnDxZvxnqn8VaVM rC1fIleCbc8hDlAFqV6R6A8F5EMMG7MFIPi9RiJx9tdQj1tu/kBK/QJp2kHRrkWw Ce/KRE9NDCY0M4UG5QJ44Hf4MV2iU8nnO6bQRZc8vhYJHiiG3wFwYaRH6eBUtL8k VLVlBEaUQxagm40ESVjamXXDbXVNLXHpFuCMSbTD5d43kb0JUBcnMTv92wnTUvZW bbffAZhlFrNB7nuh6wAapM9hHlVGfLDtSnI7a/M5i7Xj6YDIx8I= =9gev -----END PGP SIGNATURE----- --IUQUragEon+AR9lB--