Fix free memory on OpenBSD
This commit is contained in:
parent
b01f0eb22f
commit
148742e1fe
1 changed files with 1 additions and 1 deletions
2
fetch
2
fetch
|
@ -643,7 +643,7 @@ getmemory () {
|
|||
memtotal=$(dmesg | awk '/real mem/ {printf $5}')
|
||||
memtotal=${memtotal/\(/}
|
||||
memtotal=${memtotal/)MB/}
|
||||
memfree=$(top -d 1 | awk '/Real:/ {print $4}')
|
||||
memfree=$(top -d 1 | awk '/Real:/ {print $6}')
|
||||
memfree=${memfree/M/}
|
||||
memused=$((memtotal - memfree))
|
||||
|
||||
|
|
Loading…
Reference in a new issue