diff options
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -38,9 +38,10 @@ int main(int argc, char* argv[]) { } // Calculate max memory usage and average memory usage - if(status.memmax < (minfo.used)) - status.memmax = minfo.used; - status.memavg = (((status.count - 1) * status.memavg) + minfo.used) / status.count; + if(status.memusedmax < (minfo.used)) + status.memusedmax = minfo.used; + status.memusedavg = (((status.count - 1) * status.memusedavg) + minfo.used) / status.count; + status.memtotal = minfo.total; // Calculate load max and incremental load average double load = cpuinfo_load1m(); |