summaryrefslogtreecommitdiff
path: root/lib/tar/write_header.c
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-10-07 14:44:17 +0200
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-10-07 14:46:40 +0200
commit267d5318e1cbf69a071b5188dda50310af2f2f8b (patch)
tree9b17035763ab4c69458f28fe37258713c45920a5 /lib/tar/write_header.c
parent3a7d758d1d5a9b6499bdc3f75077932ba66f89d7 (diff)
Cleanup: Move padd_file function to libtar
It's only ever used for padding tarballs. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'lib/tar/write_header.c')
-rw-r--r--lib/tar/write_header.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/tar/write_header.c b/lib/tar/write_header.c
index 4c8caa2..14802c0 100644
--- a/lib/tar/write_header.c
+++ b/lib/tar/write_header.c
@@ -109,7 +109,7 @@ static int write_gnu_header(int fd, const struct stat *orig,
return -1;
}
- return padd_file(fd, payload_len, 512);
+ return padd_file(fd, payload_len);
}
static size_t num_digits(size_t num)
@@ -152,7 +152,7 @@ static int write_schily_xattr(int fd, const struct stat *orig,
dprintf(fd, "%zu %s%s=%s\n", len, prefix, it->key, it->value);
}
- return padd_file(fd, total_size, 512);
+ return padd_file(fd, total_size);
}
int write_tar_header(int fd, const struct stat *sb, const char *name,