Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
monicasarbu committed May 5, 2017
1 parent 41168de commit 3b1eb28
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sigar_linux_common.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ func (self *Mem) Get() error {
}

kern := buffers + cached
if available == 0 {
if available > 0 {
// MemAvailable is in /proc/meminfo (kernel 3.14+)
self.ActualFree = self.Free + kern
} else {
self.ActualFree = available
} else {
self.ActualFree = self.Free + kern
}

self.Used = self.Total - self.ActualFree
Expand Down

0 comments on commit 3b1eb28

Please sign in to comment.