sload.f2fs: fix the missing of bit mask for file type
PATCH 1/1 sload.f2fs: fix the missing of bit mask for file type
Fix the missing of bit mask for the file type bit fields.
--- fsck/sload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fsck/sload.c +1 -1
@@ -157,7 +157,7 @@ static void set_inode_metadata(struct dentry *de) de->size = stat.st_size; de->mode = stat.st_mode & - (S_ISUID |S_ISGID |S_ISVTX |S_IRWXU |S_IRWXG |S_IRWXO ); + (S_IFMT |S_ISUID |S_ISGID |S_ISVTX |S_IRWXU |S_IRWXG |S_IRWXO );if (c.fixed_time ==-1 && c.from_dir) de->mtime = stat.st_mtime;else
Signature · 6 lines
2.16.2 ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Quoted 4 lines · Junling Zheng
Fix the missing of bit mask for the file type bit fields.
Signed-off-by Junling Zheng <[email protected]>Signed-off-by Sheng Yong <[email protected]>
Thanks,
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Hi, Jaegeuk
Could you please merge this fix into external/f2fs-tools repo for AOSP? Since we found this bug while using sload feature in Android P :)
Thanks,
Junling
Quoted 14 lines · Junling Zheng
Fix the missing of bit mask for the file type bit fields.
Signed-off-by Junling Zheng <[email protected]>Signed-off-by Sheng Yong <[email protected]>--- fsck/sload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fsck/sload.c +0
-0
fsck/sload.c static void set_inode_metadata(struct dentry *de) · line 163
Quoted 8 lines
fsck/sload.c +1
-1@@ -157,7 +157,7 @@ static void set_inode_metadata(struct dentry *de) de->size = stat.st_size; de->mode = stat.st_mode & - (S_ISUID |S_ISGID |S_ISVTX |S_IRWXU |S_IRWXG |S_IRWXO ); + (S_IFMT |S_ISUID |S_ISGID |S_ISVTX |S_IRWXU |S_IRWXG |S_IRWXO );if (c.fixed_time ==-1 && c.from_dir) de->mtime = stat.st_mtime;else
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Quoted 4 lines · Junling Zheng
Hi, Jaegeuk
Could you please merge this fix into external/f2fs-tools repo for AOSP? Since we found this bug while using sload feature in Android P :)
Sure. Will prepare soon.
Thanks,
Quoted 19 lines
Thanks,
JunlingQuoted 14 lines · Junling Zheng
Fix the missing of bit mask for the file type bit fields.
Signed-off-by Junling Zheng <[email protected]>Signed-off-by Sheng Yong <[email protected]>--- fsck/sload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fsck/sload.c +0
-0@@ -157,7 +157,7 @@ static void set_inode_metadata(struct dentry *de)
Quoted 9 lines
fsck/sload.c static void set_inode_metadata(struct dentry *de) · line 163
Quoted 8 lines
fsck/sload.c +1
-1de->size = stat.st_size; de->mode = stat.st_mode & - (S_ISUID |S_ISGID |S_ISVTX |S_IRWXU |S_IRWXG |S_IRWXO ); + (S_IFMT |S_ISUID |S_ISGID |S_ISVTX |S_IRWXU |S_IRWXG |S_IRWXO );if (c.fixed_time ==-1 && c.from_dir) de->mtime = stat.st_mtime;else
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot