aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorDaniel Golle <daniel@makrotopia.org>2023-05-12 02:17:21 +0200
committerDaniel Golle <daniel@makrotopia.org>2023-05-12 02:27:17 +0200
commitf1f87ef3508c1e168b686d72e57166515999c313 (patch)
tree6204ec671ea6aabe119b0c5f7d7c895a3e156ed8 /tools
parent0ce356bbba44ae573aca7104ca4d547bcdf816c5 (diff)
downloadupstream-f1f87ef3508c1e168b686d72e57166515999c313.tar.gz
upstream-f1f87ef3508c1e168b686d72e57166515999c313.tar.bz2
upstream-f1f87ef3508c1e168b686d72e57166515999c313.zip
tools: squashfs3-lzma: generate reproducible output
Always initialize header with zeros as otherwise we may end up with uninitialized memory which ruins reproducibility. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/squashfs3-lzma/patches/150-fix-unitialized-memory.patch11
1 files changed, 11 insertions, 0 deletions
diff --git a/tools/squashfs3-lzma/patches/150-fix-unitialized-memory.patch b/tools/squashfs3-lzma/patches/150-fix-unitialized-memory.patch
new file mode 100644
index 0000000000..ad3b820894
--- /dev/null
+++ b/tools/squashfs3-lzma/patches/150-fix-unitialized-memory.patch
@@ -0,0 +1,11 @@
+--- a/squashfs-tools/mksquashfs.c
++++ b/squashfs-tools/mksquashfs.c
+@@ -1822,7 +1822,7 @@ int main(int argc, char *argv[])
+ {
+ struct stat buf, source_buf;
+ int i;
+- squashfs_super_block sBlk;
++ squashfs_super_block sBlk = {};
+ char *b, *root_name = NULL;
+ int be, nopad = FALSE, keep_as_directory = FALSE, orig_be;
+ squashfs_inode inode;