(tar_from_header): minor width cleanup.

Use UINTMAX_WIDTH rather than computing it by hand.

Sync with GNU tar fbc60c2334326fc2f748226abe76190ecf39a26b.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2024-09-01 11:56:38 +03:00
parent 2aeff547ca
commit c9288158bc

View File

@ -362,8 +362,7 @@ tar_from_header (const char *where0, size_t digs, char const *type, intmax_t min
uintmax_t topbits;
signbit = *where & (1 << (LG_256 - 2));
topbits =
(((uintmax_t) - signbit) << (CHAR_BIT * sizeof (uintmax_t) - LG_256 - (LG_256 - 2)));
topbits = ((uintmax_t) - signbit) << (UINTMAX_WIDTH - LG_256 - (LG_256 - 2));
value = (*where++ & ((1 << (LG_256 - 2)) - 1)) - signbit;