mirror of
https://github.com/bootandy/dust.git
synced 2026-06-08 11:29:05 +03:00
Fix bug for devices and apparent size
If apparent_size was set and ignore files on other devices was set then the latter flat would not work. Fix this bug
This commit is contained in:
+3
-1
@@ -173,7 +173,7 @@ fn should_ignore_file(
|
||||
inodes: &mut HashSet<(u64, u64)>,
|
||||
maybe_inode: Option<(u64, u64)>,
|
||||
) -> bool {
|
||||
if !apparent_size {
|
||||
|
||||
if let Some(inode_dev_pair) = maybe_inode {
|
||||
// Ignore files on different devices (if flag applied)
|
||||
if restricted_filesystems.is_some()
|
||||
@@ -184,6 +184,8 @@ fn should_ignore_file(
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
if !apparent_size {
|
||||
// Ignore files already visited or symlinked
|
||||
if inodes.contains(&inode_dev_pair) {
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user