mirror of https://github.com/aristocratos/btop.git
Fixed incorrect used and available memory for OSX
This commit is contained in:
parent
eab6c58137
commit
4461a431ae
|
@ -686,7 +686,7 @@ namespace Mem {
|
|||
if (host_statistics64(mach_host_self(), HOST_VM_INFO64, (host_info64_t)&p, &info_size) == 0) {
|
||||
mem.stats.at("free") = p.free_count * Shared::pageSize;
|
||||
mem.stats.at("cached") = p.external_page_count * Shared::pageSize;
|
||||
mem.stats.at("used") = (p.active_count + p.inactive_count + p.wire_count) * Shared::pageSize;
|
||||
mem.stats.at("used") = (p.active_count + p.wire_count) * Shared::pageSize;
|
||||
mem.stats.at("available") = Shared::totalMem - mem.stats.at("used");
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue