diff options
author | Daniel Lange <DLange@git.local> | 2020-10-20 10:17:58 +0200 |
---|---|---|
committer | Daniel Lange <DLange@git.local> | 2020-10-20 10:17:58 +0200 |
commit | 9f1a9ab2c2d5984887f5b821afd34a8480790877 (patch) | |
tree | 940c5d8efa9a5c8d4db2407f10359a4ea6fb50a5 /darwin | |
parent | a0fb6e34f9e2dd83f535f3058f1a358637773298 (diff) | |
parent | 96e2a4259eb0cdf279b83d899f805d274d13a94f (diff) |
Merge branch 'header_pause' of cgzones/htop
Continue to update generic data in paused mode
Diffstat (limited to 'darwin')
-rw-r--r-- | darwin/DarwinProcessList.c | 6 | ||||
-rw-r--r-- | darwin/DarwinProcessList.h | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/darwin/DarwinProcessList.c b/darwin/DarwinProcessList.c index 10d0697f..f6f08b50 100644 --- a/darwin/DarwinProcessList.c +++ b/darwin/DarwinProcessList.c @@ -144,7 +144,7 @@ void ProcessList_delete(ProcessList* this) { free(this); } -void ProcessList_goThroughEntries(ProcessList* super) { +void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate) { DarwinProcessList *dpl = (DarwinProcessList *)super; bool preExisting = true; struct kinfo_proc *ps; @@ -158,6 +158,10 @@ void ProcessList_goThroughEntries(ProcessList* super) { ProcessList_getVMStats(&dpl->vm_stats); openzfs_sysctl_updateArcStats(&dpl->zfs); + // in pause mode only gather global data for meters (CPU/memory/...) + if (pauseProcessUpdate) + return; + /* Get the time difference */ dpl->global_diff = 0; for(int i = 0; i < dpl->super.cpuCount; ++i) { diff --git a/darwin/DarwinProcessList.h b/darwin/DarwinProcessList.h index 58102d35..44a847dc 100644 --- a/darwin/DarwinProcessList.h +++ b/darwin/DarwinProcessList.h @@ -51,6 +51,6 @@ ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* pidMatchList, ui void ProcessList_delete(ProcessList* this); -void ProcessList_goThroughEntries(ProcessList* super); +void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate); #endif |