Don't reuse fs_config for root dir, just like make_ext4fs
Change-Id: I1891ae371cea5dc27ce55673f806654a9475c849
Signed-off-by: Mohamad Ayyash <mkayyash@google.com>
diff --git a/squashfs-tools/mksquashfs.c b/squashfs-tools/mksquashfs.c
index 033bc8e..3501a9f 100644
--- a/squashfs-tools/mksquashfs.c
+++ b/squashfs-tools/mksquashfs.c
@@ -3168,12 +3168,12 @@
pathname, strerror(errno));
/* ANDROID CHANGES START*/
#ifdef ANDROID
- if (android_config) {
- if (mount_point)
- android_fs_config(fs_config_func, mount_point, &buf, target_out_path, &caps);
- else
- android_fs_config(fs_config_func, pathname, &buf, target_out_path, &caps);
- }
+ buf.st_mode = S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH; // root mode
+ buf.st_uid = 0;
+ buf.st_gid = 0;
+ buf.st_mtime = time(NULL);
+ buf.st_dev = 0;
+ buf.st_ino = 0;
#endif
/* ANDROID CHANGES END */
dir_ent->inode = lookup_inode(&buf);