GNU bug report logs - #30936
gzip -l reports wrong size for decompressed files larger than 4GB

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: gzip; Reported by: Wolfgang Formann <wformann@HIDDEN>; merged with #17804, #29089, #30935, #38766, #42965, #48424, #52227; dated Sun, 25 Mar 2018 13:31:03 UTC; Maintainer for gzip is bug-gzip@HIDDEN.
Merged 17804 29089 30935 30936 38766 42965 48424 52227. Request was from Paul Eggert <eggert@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 25 Mar 2018 13:30:38 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Mar 25 09:30:38 2018
Received: from localhost ([127.0.0.1]:52224 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1f05jJ-0005sb-Q5
	for submit <at> debbugs.gnu.org; Sun, 25 Mar 2018 09:30:38 -0400
Received: from eggs.gnu.org ([208.118.235.92]:41090)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <wformann@HIDDEN>) id 1f01kx-0003qr-GL
 for submit <at> debbugs.gnu.org; Sun, 25 Mar 2018 05:16:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <wformann@HIDDEN>) id 1f01kr-0004uJ-B7
 for submit <at> debbugs.gnu.org; Sun, 25 Mar 2018 05:15:58 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_40,FREEMAIL_FROM
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:60139)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <wformann@HIDDEN>) id 1f01kr-0004u9-7z
 for submit <at> debbugs.gnu.org; Sun, 25 Mar 2018 05:15:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60287)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <wformann@HIDDEN>) id 1f01kp-0004hC-Uk
 for bug-gzip@HIDDEN; Sun, 25 Mar 2018 05:15:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <wformann@HIDDEN>) id 1f01kl-0004o8-Vq
 for bug-gzip@HIDDEN; Sun, 25 Mar 2018 05:15:55 -0400
Received: from mx009.vodafonemail.xion.oxcs.net ([153.92.174.39]:10503)
 by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <wformann@HIDDEN>) id 1f01kl-0004lf-PP
 for bug-gzip@HIDDEN; Sun, 25 Mar 2018 05:15:51 -0400
Received: from vsmx002.vodafonemail.xion.oxcs.net (unknown [192.168.75.192])
 by mta-6-out.mta.xion.oxcs.net (Postfix) with ESMTP id 50F4AD9B35D
 for <bug-gzip@HIDDEN>; Sun, 25 Mar 2018 09:15:49 +0000 (UTC)
Received: from [192.168.0.198] (unknown [109.90.4.22])
 by mta-6-out.mta.xion.oxcs.net (Postfix) with ESMTPA id 15B08199C2F
 for <bug-gzip@HIDDEN>; Sun, 25 Mar 2018 09:15:46 +0000 (UTC)
From: Wolfgang Formann <wformann@HIDDEN>
Subject: gzip -l reports wrong size for decompressed files larger than 4GB
To: bug-gzip@HIDDEN
Message-ID: <6e613212-726a-8628-9f7e-620b19c0b6a4@HIDDEN>
Date: Sun, 25 Mar 2018 11:15:46 +0200
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:49.0) Gecko/20100101
 Firefox/49.0 SeaMonkey/2.46
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-VADE-STATUS: LEGIT
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
 [fuzzy]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.1 (----)
X-Debbugs-Envelope-To: submit
X-Mailman-Approved-At: Sun, 25 Mar 2018 09:30:36 -0400
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -4.1 (----)

Hello!

I am using gzip 1.6 from openSUSE Leap 42.3 with latest patches

$ file /usr/bin/gzip
/usr/bin/gzip: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter 
/lib64/ld-linux-x86-64.so.2, for GNU/Linux 3.0.0, BuildID[sha1]=7103d56e17e6f81a52db927e393dce601c3af0e1, stripped

There is a compressed file available at https://data.dnb.de/opendata/GND.rdf.gz which has a size of 1.232.465.678 bytes. 
Uncompressed it will have a size of 19.465.374.298

The problem is:
$ gzip -l GND.rdf.gz
          compressed        uncompressed  ratio uncompressed_name
          1232465678          2285505114  46.1% GND.rdf

This number 2285505114 is actually the lower 32 bits of the real size 19GB.
$ echo "19465374298-16*1024*1024*1024" | bc
2285505114

Such a behaviour is okay for 32-bit software, 64-bit should show correct numbers.

Thanks
Wolfgang





Acknowledgement sent to Wolfgang Formann <wformann@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gzip@HIDDEN. Full text available.
Report forwarded to bug-gzip@HIDDEN:
bug#30936; Package gzip. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Wed, 1 Dec 2021 23:45:01 UTC

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