diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-04-27 20:19:46 +0200 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-04-27 20:41:21 +0200 |
commit | 687e44297071c95004d47e389fc409b951a8f9ff (patch) | |
tree | 6383b32c960a32bfb1393b774cc72a54fe2b94b1 /bin/gensquashfs/mkfs.h | |
parent | 6a0d2f053ba32c63bb9a3c40135f8d5bb46c9cb0 (diff) |
Cleanup/fix: gensquashfs: split directory scanning from xattr scanning
On the one hand, this commit cleanes the code a bit by splitting
the "scan directory contents" code from the "scan xattrs from
directory contents" and moving the later in a seperate file.
On the other hand, the xattr scanning is now done *after* the fstree
is post processed, which includes sorting it. This way, the xattrs
are always added in a deterministic, reproducible order.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'bin/gensquashfs/mkfs.h')
-rw-r--r-- | bin/gensquashfs/mkfs.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/bin/gensquashfs/mkfs.h b/bin/gensquashfs/mkfs.h index 9a36d8c..6aa0c87 100644 --- a/bin/gensquashfs/mkfs.h +++ b/bin/gensquashfs/mkfs.h @@ -63,9 +63,10 @@ enum { void process_command_line(options_t *opt, int argc, char **argv); -int fstree_from_dir(fstree_t *fs, const char *path, void *selinux_handle, - sqfs_xattr_writer_t *xwr, unsigned int flags); +int fstree_from_dir(fstree_t *fs, const char *path, unsigned int flags); +int xattrs_from_dir(fstree_t *fs, const char *path, void *selinux_handle, + sqfs_xattr_writer_t *xwr, unsigned int flags); void *selinux_open_context_file(const char *filename); |