From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Wed, 11 Dec 2019 01:57:54 +0300 From: "Dmitry V. Levin" To: ALT Devel discussion list Message-ID: <20191210225754.GA32733@altlinux.org> References: <20191210152343.33867-1-darktemplar@altlinux.org> <20191210152343.33867-27-darktemplar@altlinux.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="LZvS9be/3tNcYl/X" Content-Disposition: inline In-Reply-To: <20191210152343.33867-27-darktemplar@altlinux.org> Subject: Re: [devel] [PATCH for apt 26/38] Fix warning about truncation of value of pkgCache::Header::HeaderSz X-BeenThere: devel@lists.altlinux.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: ALT Linux Team development discussions List-Id: ALT Linux Team development discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Dec 2019 22:57:55 -0000 Archived-At: List-Archive: List-Post: --LZvS9be/3tNcYl/X Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 10, 2019 at 06:23:31PM +0300, Aleksei Nikiforov wrote: > Update types of other variables as well. What's the rationale for changing types of *all* these fields, and for choosing architecture-dependent "unsigned long" as the new type instead of "unsigned short"? > --- > apt/apt-pkg/pkgcache.h | 14 +++++++------- > 1 file changed, 7 insertions(+), 7 deletions(-) >=20 > diff --git a/apt/apt-pkg/pkgcache.h b/apt/apt-pkg/pkgcache.h > index 05a63bc..6b44522 100644 > --- a/apt/apt-pkg/pkgcache.h > +++ b/apt/apt-pkg/pkgcache.h > @@ -175,13 +175,13 @@ struct pkgCache::Header > unsigned long OptionsHash; > =20 > // Size of structure values > - unsigned short HeaderSz; > - unsigned short PackageSz; > - unsigned short PackageFileSz; > - unsigned short VersionSz; > - unsigned short DependencySz; > - unsigned short ProvidesSz; > - unsigned short VerFileSz; > + unsigned long HeaderSz; > + unsigned long PackageSz; > + unsigned long PackageFileSz; > + unsigned long VersionSz; > + unsigned long DependencySz; > + unsigned long ProvidesSz; > + unsigned long VerFileSz; > =20 > // Structure counts > unsigned long PackageCount; --=20 ldv --LZvS9be/3tNcYl/X Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIcBAEBCAAGBQJd8CLyAAoJEAVFT+BVnCUIj04P/3whKj5gOWZ+01VBEGx6bXd6 AZj38epNixrwQc8bw++BADMCp2QdDQ5K8XWb4T9i88c0DTc60XtY3Ya1MO9hsGT0 gQGOIWWpnxz9t7nDvuaCL8MWIBgZxACMt+VubwvcBMJ+T8WpnngZMv0OyYpVven9 tdbF7xNiVD60uxMJOsA3535x1VTETq0k+MflVKV6sB9+JSsmomMv1mJUIPARWjUH iKh90x+hO+BJid2qIY1N+ao6VhoaAnMZNpRnzPX7My9nNiX9ipxn+2uBG2UHtXRb SuJn+PmBaXFeNGJx/rzMOmMfrIRuVxw5a+2UTj1Uu4IbtbMj9dYCxnEC4LAfnbGv m/S4sqhy45bRQLNsblrLl8wSC6jiuCQYWu6G2hoIkoP+qtvh7oqyatWJ22UMvLla Rf12DNcPsvf1iOcVdr/aB4LLDQjQHLo47Fm/rd3owIF/cg0QOGx8JZ2ibqpIXtIi ceVSJEiB+l0BarbsqcysB1E1AxuiNezw52UYquV5udVVoSkOt3XsuwNyGU89/F6t R7mLEXumnNCg9HgklizejqG0Gj8vN2RIg8KPMEUvZQ5v6xp7COrPUor3kOn9I3mb zRy/CCRfH6TqR+zsc4PLy/A4gnDzsSCjkNvs3t1aJmkfXHkM7XWECh742oZP2dzg QusHnZDK40Pe6rDsXg4u =jc2v -----END PGP SIGNATURE----- --LZvS9be/3tNcYl/X--