reboot(8): print syscall error on sysctl failure
Noted by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D42561
This commit is contained in:
parent
194cc45a81
commit
a294b02fbc
|
@ -281,7 +281,7 @@ get_pageins(void)
|
||||||
len = sizeof(pageins);
|
len = sizeof(pageins);
|
||||||
if (sysctlbyname("vm.stats.vm.v_swappgsin", &pageins, &len, NULL, 0)
|
if (sysctlbyname("vm.stats.vm.v_swappgsin", &pageins, &len, NULL, 0)
|
||||||
!= 0) {
|
!= 0) {
|
||||||
warnx("v_swappgsin");
|
warn("v_swappgsin");
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
return (pageins);
|
return (pageins);
|
||||||
|
|
Loading…
Reference in New Issue