diff options
author | Michael McConville <mmcco@mykolab.com> | 2016-01-02 12:17:35 -0500 |
---|---|---|
committer | Michael McConville <mmcco@mykolab.com> | 2016-01-02 12:17:35 -0500 |
commit | ae5c01f4859e3296292bd34b2efc5a7720368d98 (patch) | |
tree | 13839787cc60136ad96e9e65332cbf46e044f23e /openbsd | |
parent | 22cfda6332bcfe89e143ed9475032bec7222bfa3 (diff) |
Use err() rather then errx() for sysctl()
So that we can see errno. Pointed out by Michael Reed.
Diffstat (limited to 'openbsd')
-rw-r--r-- | openbsd/OpenBSDProcessList.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/openbsd/OpenBSDProcessList.c b/openbsd/OpenBSDProcessList.c index eb4cd2e7..aa765a15 100644 --- a/openbsd/OpenBSDProcessList.c +++ b/openbsd/OpenBSDProcessList.c @@ -60,7 +60,7 @@ ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* pidWhiteList, ui size = sizeof(fscale); if (sysctl(fmib, 2, &fscale, &size, NULL, 0) < 0) - errx(1, "fscale sysctl call failed"); + err(1, "fscale sysctl call failed"); for (i = 0; i < pl->cpuCount; i++) { fpl->cpus[i].totalTime = 1; @@ -90,7 +90,7 @@ static inline void OpenBSDProcessList_scanMemoryInfo(ProcessList* pl) { size_t size = sizeof(uvmexp); if (sysctl(uvmexp_mib, 2, &uvmexp, &size, NULL, 0) < 0) { - errx(1, "uvmexp sysctl call failed"); + err(1, "uvmexp sysctl call failed"); } //kb_pagesize = uvmexp.pagesize / 1024; |