GNU bug report logs - #38766
bug: "gzip -l" truncates reported decompressed size to 32 bits

Previous Next

Package: gzip;

Reported by: Jason Mancini <jayrusman <at> hotmail.com>

Date: Fri, 27 Dec 2019 23:19:01 UTC

Severity: normal

Merged with 17804, 29089, 30935, 30936, 42965, 48424, 52227

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 38766 <at> debbugs.gnu.org (full text, mbox):

From: Antonio Diaz Diaz <antonio <at> gnu.org>
To: Jason Mancini <jayrusman <at> hotmail.com>
Cc: 38766 <at> debbugs.gnu.org
Subject: Re: bug#38766: bug: "gzip -l" truncates reported decompressed size
 to 32 bits
Date: Sat, 28 Dec 2019 17:36:44 +0100
Jason Mancini wrote:
> # zcat backup.bin.gz | wc -c
> 67,645,849,600
> # gzip -l backup.bin.gz
> compressed        uncompressed  ratio uncompressed_name
> 9,458,450,396    3,221,340,160 -193.6% backup.bin

This is a known limitation of the gzip format, and is documented in the manual:

http://www.gnu.org/software/gzip/manual/gzip.html#Invoking-gzip

"The gzip format represents the input size modulo 2^32, so the uncompressed 
size and compression ratio are listed incorrectly for uncompressed files 4 
GiB and larger. To work around this problem, you can use the following 
command to discover a large uncompressed file’s true size:
zcat file.gz | wc -c"


Best regards,
Antonio.





This bug report was last modified 3 years and 154 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.