add `in_use` method for `Inode` to check whether there are any hard links

pull/3/head
Szymon Walter 2018-03-19 20:42:27 +01:00
parent c798b2bdb2
commit 7dd27917bd
1 changed files with 4 additions and 0 deletions

View File

@ -119,6 +119,10 @@ impl Inode {
Ok(inode)
}
pub fn in_use(&self) -> bool {
self.hard_links > 0
}
}
bitflags! {