From 92e2c77a5b5eeabc3252ea90953ab6bd1a8944d1 Mon Sep 17 00:00:00 2001 From: David Oberhollenzer Date: Wed, 8 Feb 2023 14:08:34 +0100 Subject: libtar: remove need for skip_padding function In the istream implementation, automatically skip the padding when we reach end-of-file. Also skip file AND padding when we destroy the object. Replace the remaining instances with a simple istream_skip instead and remove the wrapper from libtar. Signed-off-by: David Oberhollenzer --- lib/tar/src/read_header.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'lib/tar/src/read_header.c') diff --git a/lib/tar/src/read_header.c b/lib/tar/src/read_header.c index 1e74841..8d3145b 100644 --- a/lib/tar/src/read_header.c +++ b/lib/tar/src/read_header.c @@ -292,13 +292,6 @@ fail: return -1; } -int skip_padding(istream_t *fp, sqfs_u64 size) -{ - size_t tail = size % 512; - - return tail ? istream_skip(fp, 512 - tail) : 0; -} - int skip_entry(istream_t *fp, sqfs_u64 size) { size_t tail = size % 512; -- cgit v1.2.3