From c72dd706565a4579153a4759573bd097bec5ed09 Mon Sep 17 00:00:00 2001 From: Monica Sarbu Date: Wed, 12 Oct 2016 17:55:06 +0200 Subject: [PATCH] Fix system.memory.actual.free on Windows --- sigar_windows.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sigar_windows.go b/sigar_windows.go index 2858da756..bf69bcc0a 100644 --- a/sigar_windows.go +++ b/sigar_windows.go @@ -102,9 +102,8 @@ func (self *Mem) Get() error { self.Total = uint64(statex.ullTotalPhys) self.Free = uint64(statex.ullAvailPhys) self.Used = self.Total - self.Free - vtotal := uint64(statex.ullTotalVirtual) - self.ActualFree = uint64(statex.ullAvailVirtual) - self.ActualUsed = vtotal - self.ActualFree + self.ActualFree = self.Free + self.ActualUsed = self.Used return nil }