]> git.ipfire.org Git - thirdparty/libarchive.git/commit
tar: Improve LFS support on 32 bit systems (#2582)
authorTobias Stoeckmann <stoeckmann@users.noreply.github.com>
Sun, 13 Apr 2025 18:07:18 +0000 (20:07 +0200)
committerGitHub <noreply@github.com>
Sun, 13 Apr 2025 18:07:18 +0000 (11:07 -0700)
commite1c8c9ef644c95882618b9ab9867d3dd1b050234
tree4f48f5b08eb90b8c684092b71e9e4b3c707ea0a0
parent8f49a18f64b42651fac9e7b210a779c076184c53
tar: Improve LFS support on 32 bit systems (#2582)

The size_t data type is only 32 bit on 32 bit sytems while off_t is
generally 64 bit to support files larger than 2 GB.

If an entry is declared to be larger than 4 GB and the entry shall be
skipped, then 32 bit systems truncate the requested amount of bytes.
This leads to different interpretation of data in tar files compared to
64 bit systems.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
Makefile.am
libarchive/archive_read_support_format_tar.c
libarchive/test/CMakeLists.txt
libarchive/test/test_read_format_tar_pax_g_large.c [new file with mode: 0644]
libarchive/test/test_read_format_tar_pax_g_large.tar.uu [new file with mode: 0644]