Report the MFT record flags properly in ntfsinfo.

This commit is contained in:
uvman 2005-11-11 23:55:14 +00:00
parent 0d651e54d3
commit 4137f63c7a
2 changed files with 18 additions and 5 deletions

View File

@ -77,7 +77,10 @@ xx/xx/2005 - 1.12.2-WIP
ntfs_crate_symlink() for Interix symbolic links creation. (Yura)
- Teach ntfs_create() to create Interix FIFOs and sockets. (Yura)
- Fix the -u option in ntfsundelete. Instead of a confusing optional
parameter, there's a new option -i with a required parameter (Rich)
parameter, there's a new option -i with a required parameter. (Rich)
- Make ntfsinfo report the MFT record flags properly, this includes
the less encountered flags, and reporting the in_use flag instead of
inverting it to unused. (Yuval)
10/10/2005 - 1.12.1 - Minor fix to location of mount.ntfs-fuse and mkfs.ntfs.

View File

@ -1875,15 +1875,25 @@ static void ntfs_dump_inode_general_info(ntfs_inode *inode)
printf("MFT record Flags:\t\t ");
if (inode_flags) {
if (!(MFT_RECORD_IN_USE & inode_flags)) {
printf("DELETED ");
if (MFT_RECORD_IN_USE & inode_flags) {
printf("IN_USE ");
inode_flags &= ~MFT_RECORD_IN_USE;
}
if (MFT_RECORD_IS_DIRECTORY & inode_flags) {
printf("DIRECTORY ");
inode_flags &= ~MFT_RECORD_IS_DIRECTORY;
}
if (~(MFT_RECORD_IN_USE | MFT_RECORD_IS_DIRECTORY) & inode_flags) {
/* The meaning of IS_4 is illusive but not its existence. */
if (MFT_RECORD_IS_4 & inode_flags) {
printf("IS_4 ");
inode_flags &= ~MFT_RECORD_IS_4;
}
if (MFT_RECORD_IS_VIEW_INDEX & inode_flags) {
printf("VIEW_INDEX ");
inode_flags &= ~MFT_RECORD_IS_VIEW_INDEX;
}
if (inode_flags)
printf("UNKNOWN:0x%04hx",inode_flags);
}
} else {
printf("none");
}