pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Fix incorrect results



Module Name:	pkgsrc-wip
Committed By:	Bartosz Kuzma <bartosz.kuzma%gmail.com@localhost>
Pushed By:	bartosz.kuzma
Date:		Mon Dec 22 20:31:39 2025 +0100
Changeset:	e552d61877bf011a93bc703bb953d15ba5fa467c

Modified Files:
	duf/files/mounts_netbsd.go

Log Message:
Fix incorrect results

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=e552d61877bf011a93bc703bb953d15ba5fa467c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 duf/files/mounts_netbsd.go | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diffs:
diff --git a/duf/files/mounts_netbsd.go b/duf/files/mounts_netbsd.go
index 938225ea68..6f55c76bc0 100644
--- a/duf/files/mounts_netbsd.go
+++ b/duf/files/mounts_netbsd.go
@@ -90,14 +90,14 @@ func mounts() ([]Mount, []string, error) {
 			Type:       fsType,
 			Opts:       opts,
 			Metadata:   stat,
-			Total:      (uint64(stat.Blocks) * uint64(stat.Bsize)),
-			Free:       (uint64(stat.Bavail) * uint64(stat.Bsize)),
-			Used:       (uint64(stat.Blocks) - uint64(stat.Bfree)) * uint64(stat.Bsize),
+			Total:      (uint64(stat.Blocks) * uint64(stat.Frsize)),
+			Free:       (uint64(stat.Bavail) * uint64(stat.Frsize)),
+			Used:       (uint64(stat.Blocks) - uint64(stat.Bfree)) * uint64(stat.Frsize),
 			Inodes:     stat.Files,
 			InodesFree: uint64(stat.Ffree),
 			InodesUsed: stat.Files - uint64(stat.Ffree),
 			Blocks:     uint64(stat.Blocks),
-			BlockSize:  uint64(stat.Bsize),
+			BlockSize:  uint64(stat.Frsize),
 		}
 		d.DeviceType = deviceType(d)
 


Home | Main Index | Thread Index | Old Index