/* SPDX-License-Identifier: GPL-3.0-or-later */ /* * padd_file.c * * Copyright (C) 2019 David Oberhollenzer */ #include "config.h" #include "tar/tar.h" #include "tar/format.h" int padd_file(sqfs_ostream_t *fp, sqfs_u64 size) { size_t padd_sz = size % TAR_RECORD_SIZE; if (padd_sz == 0) return 0; return fp->append(fp, NULL, TAR_RECORD_SIZE - padd_sz); }