diff options
author | Nathan Scott <nathans@redhat.com> | 2023-04-04 16:24:37 +1000 |
---|---|---|
committer | BenBE <BenBE@geshi.org> | 2023-04-06 00:19:54 +0200 |
commit | e7f447b6a3473a572d3e6c191128f1796477860d (patch) | |
tree | 1e8a90d216055dfe77b688fc48c0a42f18637d71 /netbsd | |
parent | c8a61850dd31ab64eb8ad83929ce86d2adbeb96c (diff) |
Refactor and consolidate dynamic meters/columns pointers
This removes the duplication of dynamic meter/column hashtable
pointers that has come in between the Settings and ProcessList
structures - only one copy of these is needed. With the future
planned dynamic screens feature adding another pointer, let us
first clean this up before any further duplication happens.
Diffstat (limited to 'netbsd')
-rw-r--r-- | netbsd/NetBSDProcessList.c | 4 | ||||
-rw-r--r-- | netbsd/NetBSDProcessList.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/netbsd/NetBSDProcessList.c b/netbsd/NetBSDProcessList.c index 197a150b..381672d6 100644 --- a/netbsd/NetBSDProcessList.c +++ b/netbsd/NetBSDProcessList.c @@ -106,14 +106,14 @@ static void NetBSDProcessList_updateCPUcount(ProcessList* super) { } } -ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* dynamicMeters, Hashtable* dynamicColumns, Hashtable* pidMatchList, uid_t userId) { +ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* pidMatchList, uid_t userId) { const int fmib[] = { CTL_KERN, KERN_FSCALE }; size_t size; char errbuf[_POSIX2_LINE_MAX]; NetBSDProcessList* npl = xCalloc(1, sizeof(NetBSDProcessList)); ProcessList* pl = (ProcessList*) npl; - ProcessList_init(pl, Class(NetBSDProcess), usersTable, dynamicMeters, dynamicColumns, pidMatchList, userId); + ProcessList_init(pl, Class(NetBSDProcess), usersTable, pidMatchList, userId); NetBSDProcessList_updateCPUcount(pl); diff --git a/netbsd/NetBSDProcessList.h b/netbsd/NetBSDProcessList.h index d228f487..d5a757fe 100644 --- a/netbsd/NetBSDProcessList.h +++ b/netbsd/NetBSDProcessList.h @@ -49,7 +49,7 @@ typedef struct NetBSDProcessList_ { } NetBSDProcessList; -ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* dynamicMeters, Hashtable* dynamicColumns, Hashtable* pidMatchList, uid_t userId); +ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* pidMatchList, uid_t userId); void ProcessList_delete(ProcessList* this); |