f2fs-tools: fix to do not dump inode if it has F2FS_NODUMP_FL flag
PATCH 1/1 f2fs-tools: fix to do not dump inode if it has F2FS_NODUMP_FL flag
Quoted from manual of chattr:
"
CHATTR(1)
...
ATTRIBUTES
A file with the 'd' attribute set is not a candidate for backup when the dump(8) program is run.
"
Once we set F2FS_NODUMP_FL flag to inode, do not allow dumping info from it.
Signed-off-by Chao Yu <[email protected]>
--- fsck/dump.c | 4 ++++ 1 file changed, 4 insertions(+)
fsck/dump.c +4 -0
@@ -605,6 +605,10 @@ static int dump_filesystem(struct f2fs_sb_info *sbi, struct node_info *ni,MSG (force,"Wrong name info\n\n" );return -1 ; } +if (le32_to_cpu (inode->i_flags) &F2FS_NODUMP_FL ) { +MSG (force,"File has nodump flag\n\n" ); +return -1 ; + } base_path = base_path ?:"./lost_found" ;if (force) goto dump;
Signature · 8 lines
2.40.1 _______________________________________________ Linux-f2fs-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel