Bug 452147 - Ark truncates/does not fully unpack .gz gzip files with trailing data
Summary: Ark truncates/does not fully unpack .gz gzip files with trailing data
Status: RESOLVED DUPLICATE of bug 447563
Alias: None
Product: ark
Classification: Applications
Component: general (show other bugs)
Version: 21.12.2
Platform: Other Linux
: NOR major
Target Milestone: ---
Assignee: Elvis Angelaccio
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-04-01 12:09 UTC by valdikss
Modified: 2022-04-02 11:20 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description valdikss 2022-04-01 12:09:51 UTC
SUMMARY
KDE Ark discards (or does not handle correctly) the latest compressed gzip block if it contains trailing "garbage", *silently* producing truncated unpacked file.


STEPS TO REPRODUCE
1. Download https://downloads.openwrt.org/releases/21.02.0/targets/x86/generic/openwrt-21.02.0-x86-generic-generic-ext4-combined.img.gz
2. Unpack it with Ark
3. Get the unpacked file 126 337 024 bytes in size

OBSERVED RESULT
The resulting file is truncated to 126 337 024 bytes, does not work as intended (disk image does not boot).


EXPECTED RESULT
The resulting file is 126 353 408 bytes in size (16 KiB more), as unpacked with gunzip.


SOFTWARE/OS VERSIONS
Operating System: Fedora Linux 35
KDE Plasma Version: 5.24.3
KDE Frameworks Version: 5.91.0
Qt Version: 5.15.2
Kernel Version: 5.16.17-200.fc35.x86_64 (64-bit)

ADDITIONAL INFORMATION
OpenWRT build system appends signature metadata to the end of .gz file, which for uncompressing program looks like a trailing garbage.
However, gunzip correctly uncompresses the file while Ark seem to discard the last compressed block, silently unpacking incomplete file.
Comment 1 Albert Astals Cid 2022-04-02 11:20:06 UTC

*** This bug has been marked as a duplicate of bug 447563 ***