aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/common/writer/finish.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/common/writer/finish.c b/lib/common/writer/finish.c
index c539579..bd1e11e 100644
--- a/lib/common/writer/finish.c
+++ b/lib/common/writer/finish.c
@@ -164,9 +164,11 @@ int sqfs_writer_finish(sqfs_writer_t *sqfs, const sqfs_writer_cfg_t *cfg)
return -1;
}
- if (padd_sqfs(sqfs->outfile, sqfs->super.bytes_used,
- cfg->devblksize)) {
- return -1;
+ if (!cfg->no_pad) {
+ if (padd_sqfs(sqfs->outfile, sqfs->super.bytes_used,
+ cfg->devblksize)) {
+ return -1;
+ }
}
if (!cfg->quiet)