From mboxrd@z Thu Jan 1 00:00:00 1970 From: Serhey Popovych Subject: Re: [PATCH iproute2] fix print_0xhex on 32 bit Date: Wed, 19 Dec 2018 22:00:38 +0200 Message-ID: <5f7269b6-f53d-b9d3-96f7-b2f86ccf759e@gmail.com> References: <20181210222701.7672-1-stephen@networkplumber.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="zc4m5qZsziIg5HJmRdQcdbCXg70eFHJBM" Cc: dedeckeh@gmail.com To: Stephen Hemminger , netdev@vger.kernel.org Return-path: Received: from mail-wr1-f67.google.com ([209.85.221.67]:36313 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729498AbeLSUAt (ORCPT ); Wed, 19 Dec 2018 15:00:49 -0500 Received: by mail-wr1-f67.google.com with SMTP id u4so19814280wrp.3 for ; Wed, 19 Dec 2018 12:00:47 -0800 (PST) In-Reply-To: <20181210222701.7672-1-stephen@networkplumber.org> Sender: netdev-owner@vger.kernel.org List-ID: This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --zc4m5qZsziIg5HJmRdQcdbCXg70eFHJBM Content-Type: multipart/mixed; boundary="yiDxoYrHmaUSRie8JB3HZAVQGIPzoIf0i"; protected-headers="v1" From: Serhey Popovych To: Stephen Hemminger , netdev@vger.kernel.org Cc: dedeckeh@gmail.com Message-ID: <5f7269b6-f53d-b9d3-96f7-b2f86ccf759e@gmail.com> Subject: Re: [PATCH iproute2] fix print_0xhex on 32 bit References: <20181210222701.7672-1-stephen@networkplumber.org> In-Reply-To: <20181210222701.7672-1-stephen@networkplumber.org> --yiDxoYrHmaUSRie8JB3HZAVQGIPzoIf0i Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Stephen Hemminger wrote: > The argument to print_0xhex is converted to unsigned long long > so the format string give for normal printout has to be some > variant of %llx. Otherwise, bogus values will be printed on > 32 bit platforms. Sorry it is too late and change is merged as commit 90c5c969f0b9 ("fix print_0xhex on 32 bit") but I want to ask following: $ printf '0x%llx !=3D %#llx\n' 0 0 0x0 !=3D 0 So we potentially can get "tos 0" vs "tos 0x0" previously. Is that expected and will not cause any compatibility problems? It is clear that 0 is always zero, but some code may rely on 0x form even for zero. What do you think? Thanks. --yiDxoYrHmaUSRie8JB3HZAVQGIPzoIf0i-- --zc4m5qZsziIg5HJmRdQcdbCXg70eFHJBM Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQEcBAEBAgAGBQJcGqNsAAoJEBTawMmQ61bBLsMIAMloBWHAyVvz+cpBd4k7OunN PtsY/NOIVW7C9gQd53wSohuBIgmdtCBS1g2NNR/hsjEufyTyMxiWja/EadW7ueiH DwjyrKQRRpNtNAy3wA+ExrRC1tFA34YYnkJH5jUZgl+7pBCfffpxPFcJG+NcPi+7 AlrkVq8K2iMkFN1CJ1VabKuxKMH3hS7yGQSFKHU3xDgwozlJr+Iuk5+Vsb11IErF /7XKPUQv2LLGXs5iJw6c/I6mE8AIVOL7NDq7Rrw6rwNtLxURjpX3BbEqzb5Ht/hN 3ngU8sws100LjaWfZAC2trkuGk1etl3TTfcGKeye0tG5eL/KsiOTrMD20XOV8pc= =7aAF -----END PGP SIGNATURE----- --zc4m5qZsziIg5HJmRdQcdbCXg70eFHJBM--