summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2020-12-15 11:07:12 +0100
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2020-12-15 11:07:12 +0100
commitefa204aedf3578d193b2832b42cf365c7aee48f9 (patch)
tree310f5e01aa656aeaf791808e14033eb3d40b5ea0 /bin
parentf138e4a24919682cf477cf93ae47b9a89bb5a3f0 (diff)
libfstree: make the directory scanning code a little more generic
- Instead of using the fstree root, let the caller specify it. - Add a flag to prevent recursion into sub directories. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'bin')
-rw-r--r--bin/gensquashfs/mkfs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/gensquashfs/mkfs.c b/bin/gensquashfs/mkfs.c
index 6f26d56..4120242 100644
--- a/bin/gensquashfs/mkfs.c
+++ b/bin/gensquashfs/mkfs.c
@@ -191,8 +191,10 @@ int main(int argc, char **argv)
}
if (opt.infile == NULL) {
- if (fstree_from_dir(&sqfs.fs, opt.packdir, opt.dirscan_flags))
+ if (fstree_from_dir(&sqfs.fs, sqfs.fs.root,
+ opt.packdir, opt.dirscan_flags)) {
goto out;
+ }
} else {
if (read_fstree(&sqfs.fs, &opt, sqfs.xwr, sehnd))
goto out;