Fix FreeBSD mem free

This commit is contained in:
Dylan 2016-01-18 17:39:23 +11:00
parent 6f1ed5c0b7
commit b6b4e09287

2
fetch
View file

@ -645,7 +645,7 @@ getmemory () {
memtotal=$(dmesg | awk '/real mem/ {printf $5}')
memtotal=${memtotal/\(/}
memtotal=${memtotal/)MB/}
memfree=$(top -d 1 | awk '/Mem:/ {print $10}')
memfree=$(top -d 1 | awk '/Mem:/ {printf $10}')
memfree=${memfree/M/}
memused=$((memtotal - memfree))