Merge branch 'arc-is-not-cache' of https://github.com/multiplexd/htop into multiplexd-arc-is-not-cache

This commit is contained in:
Nathan Scott 2020-09-28 14:44:12 +10:00
commit 400178a89b
1 changed files with 7 additions and 0 deletions

View File

@ -202,6 +202,8 @@ double Platform_setCPUValues(Meter* this, int cpu) {
void Platform_setMemoryValues(Meter* this) { void Platform_setMemoryValues(Meter* this) {
ProcessList* pl = (ProcessList*) this->pl; ProcessList* pl = (ProcessList*) this->pl;
LinuxProcessList* lpl = (LinuxProcessList*) this->pl;
long int usedMem = pl->usedMem; long int usedMem = pl->usedMem;
long int buffersMem = pl->buffersMem; long int buffersMem = pl->buffersMem;
long int cachedMem = pl->cachedMem; long int cachedMem = pl->cachedMem;
@ -210,6 +212,11 @@ void Platform_setMemoryValues(Meter* this) {
this->values[0] = usedMem; this->values[0] = usedMem;
this->values[1] = buffersMem; this->values[1] = buffersMem;
this->values[2] = cachedMem; this->values[2] = cachedMem;
if (lpl->zfs.enabled != 0) {
this->values[0] -= lpl->zfs.size;
this->values[2] += lpl->zfs.size;
}
} }
void Platform_setSwapValues(Meter* this) { void Platform_setSwapValues(Meter* this) {