mirror of
https://github.com/tw93/Mole.git
synced 2026-02-16 20:29:10 +00:00
Fix disk space check size error
This commit is contained in:
BIN
bin/analyze-go
BIN
bin/analyze-go
Binary file not shown.
BIN
bin/status-go
BIN
bin/status-go
Binary file not shown.
@@ -453,6 +453,10 @@ func collectDisks() ([]DiskStatus, error) {
|
|||||||
if strings.HasPrefix(part.Mountpoint, "/System/Volumes/") {
|
if strings.HasPrefix(part.Mountpoint, "/System/Volumes/") {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
// Skip private volumes
|
||||||
|
if strings.HasPrefix(part.Mountpoint, "/private/") {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if seenDevice[part.Device] {
|
if seenDevice[part.Device] {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
@@ -464,7 +468,9 @@ func collectDisks() ([]DiskStatus, error) {
|
|||||||
if usage.Total < 1<<30 {
|
if usage.Total < 1<<30 {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
volKey := fmt.Sprintf("%s:%d", part.Fstype, usage.Total>>30)
|
// For APFS volumes, use a more precise dedup key (bytes level)
|
||||||
|
// to handle shared storage pools properly
|
||||||
|
volKey := fmt.Sprintf("%s:%d", part.Fstype, usage.Total)
|
||||||
if seenVolume[volKey] {
|
if seenVolume[volKey] {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user