From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gandalf.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by passt.top (Postfix) with ESMTPS id 5E9995A026D for ; Tue, 3 Oct 2023 04:36:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=201602; t=1696300594; bh=w9sgSOHe5E+hw4nsvyscSqAR5b2HLychJU9cwOiS994=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=L6GVDPT/2sT1I3Z7LpsXp20p7nzot190p6joS6g60pvW1wk5waL8NSOaEtzJhg1Ta qQM+EGK08mp0dY+l34RJ2kqjU5S73w65Qeogq21XNea237hcKRQa7MTf2MfnM560Ho oLqoEGuxoib30+/YLlv18s4s2vYdE2ADAXOkdFbM= Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4S025G2KFyz4xQ3; Tue, 3 Oct 2023 13:36:34 +1100 (AEDT) Date: Tue, 3 Oct 2023 13:36:12 +1100 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH 0/4] RFC: Updates for cppcheck-2.12 warnings Message-ID: References: <20230929055022.48624-1-david@gibson.dropbear.id.au> <20230929173134.4f7c1947@elisabeth> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="+7P/t54Gg+oHZCv1" Content-Disposition: inline In-Reply-To: <20230929173134.4f7c1947@elisabeth> Message-ID-Hash: LI72KWZQM42DVU6ILTS656YMU6SHHDFL X-Message-ID-Hash: LI72KWZQM42DVU6ILTS656YMU6SHHDFL X-MailFrom: dgibson@gandalf.ozlabs.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: passt-dev@passt.top X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --+7P/t54Gg+oHZCv1 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Sep 29, 2023 at 05:31:34PM +0200, Stefano Brivio wrote: > On Fri, 29 Sep 2023 15:50:18 +1000 > David Gibson wrote: >=20 > > cppcheck 2.12 (which Fedora 38 has updated, for one) introduces a > > number of new warnings. Unfortunately, at least one of these is a > > clear bug in cppcheck. > >=20 > > This series fixes a number of the new warnings reported in passt > > (patches 1..3) and works around the remaining cppcheck bug (patch 4). > > I'm pretty confident that patches 1 & 2 are safe and beneficial to > > apply regardless of which cppcheck we're using. > >=20 > > Patch 3 is a little more dubious, because it potentially increases the > > cppcheck runtime. On my system it doesn't seem to make a significant > > difference, but that might not always stay true. >=20 > On my system, it's 23 seconds instead of 21... I don't really see a > problem with that. Right, it's like 16s vs 15s for me. I was just a bit concerned they might add more, very expensive tests under the "exhaustive" set later on. > > Patch 4 is a tricky one. It applies a specific suppression to work > > around the cppcheck bug. That's necessary to get a pass with the > > currently available cppcheck. However, it's ugly and we'd like to > > remove it once the bug is fixed, but have no obvious way to remind us > > to do that. What we want to do here kind of depends how long it takes > > the bug to be fixed, which isn't clear at the moment. >=20 > I don't see a big issue with this either, we already have one > suppression like that in tcp_clamp_window() where we kind of identified > the issue but it hasn't been solved yet. >=20 > Once it's fixed, we'll hopefully notice and drop the suppression if > cppcheck 2.12 is old enough by then, but if we don't, I don't think it's > a drama. >=20 > The whole series looks good to me by the way. Ok. Well, apply whenever you're ready then, I guess. --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --+7P/t54Gg+oHZCv1 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmUbfhUACgkQzQJF27ox 2Gc0sxAAgxCmHsvZvuhwx8gv8NH/oMXWk1PUPLWxdGZG5F+DjbfrZ2u5tNFiYXhG EVyt6zVFP+vzL25KEhQle9MaL0nTFtz/qrrtpb0+SDjDhj8Mjte6Tsr0MdR1jnTa UyYWDaGrSrUqbbIl2amFyU+/RhnYhXRObT81S3oZTt8kGovxAS1dSNzF5/NI8U3v PSn1oaxaK2JTnKeE9pH9uqcV07y7iN9y9sNVz7NJUjRdxOZlrrDC1cWJbCG24Xre 7xINTjPGPMOClDl+AopBnpKQpfi1SloVFIcBLmJGl2sMfnbPpSHGTY+89TQTstkM uO3fPBv5dB2UFrPgVyn6cw2O8gm5moDOlh1qclgYiumRsrg6oNJP1H6DRN7pw/o6 Ajx25rXZSozVSCRugncR86TYHBEgZcWu3pViYiDLlb9YRVYyHMJULqF5Qu0ippqx +6/neLFpTgkoA6vzxcJ9R4BfJEFPEL2us4flZ1I9DkG+EMwKEBQENDS5m9e0OyJG sDPVwf6wi+o0slb7b7RkpA2BVmJml5wipaNSt24UHG8KmdW3yeNfcAStGFbz3XaQ 2S7/Mz9cgUAHxKxq0gTvZOuhN3uF+nMDthceqdKTa/EsB9AbEOATZikIbKEtg7VD oIdXY12AgF9IwATWRFqChF5woN6+I2yE+IoM94E+oWoZ3H3zfnU= =FNvh -----END PGP SIGNATURE----- --+7P/t54Gg+oHZCv1--