aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortrinity-1686a <trinity@deuxfleurs.fr>2023-10-15 17:57:27 +0200
committertrinity-1686a <trinity@deuxfleurs.fr>2023-10-15 17:57:27 +0200
commitc7f5dcd953ff1fdfa002a8bccfb43eafcc6fddd4 (patch)
treee90e6de1908fd97eb79928d151ccc239fb416363
parentd8263fdf92532cedaa11efb715971e2b0613924e (diff)
downloadgarage-c7f5dcd953ff1fdfa002a8bccfb43eafcc6fddd4.tar.gz
garage-c7f5dcd953ff1fdfa002a8bccfb43eafcc6fddd4.zip
fix compilation on macos
fsblkcnt_t is ony 32b there, so we have to do an additional cast
-rw-r--r--src/rpc/system.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rpc/system.rs b/src/rpc/system.rs
index 78fcc74b..4b40bec4 100644
--- a/src/rpc/system.rs
+++ b/src/rpc/system.rs
@@ -899,8 +899,8 @@ impl NodeStatus {
use nix::sys::statvfs::statvfs;
let mount_avail = |path: &Path| match statvfs(path) {
Ok(x) => {
- let avail = x.blocks_available() * x.fragment_size() as u64;
- let total = x.blocks() * x.fragment_size() as u64;
+ let avail = x.blocks_available() as u64 * x.fragment_size() as u64;
+ let total = x.blocks() as u64 * x.fragment_size() as u64;
Some((x.filesystem_id(), avail, total))
}
Err(_) => None,