From 97656ec1554b4f7cfe8a8f398e31e09fbe745196 Mon Sep 17 00:00:00 2001 From: ngie Date: Sat, 12 Mar 2016 19:09:51 +0000 Subject: [PATCH] MFC r295079: Fix the type for hw.ncpu, so sysctlbyname doesn't consistently fail on 64-bit architectures where sizeof(int) != sizeof(size_t). PR: 206758 git-svn-id: svn://svn.freebsd.org/base/stable/10@296756 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f --- libexec/atrun/atrun.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libexec/atrun/atrun.c b/libexec/atrun/atrun.c index 1e25766c4..7b11e7bb1 100644 --- a/libexec/atrun/atrun.c +++ b/libexec/atrun/atrun.c @@ -459,8 +459,9 @@ main(int argc, char *argv[]) int c; int run_batch; #ifdef __FreeBSD__ - size_t ncpu, ncpusz; + size_t ncpusz; double load_avg = -1; + int ncpu; #else double load_avg = LOADAVG_MX; #endif -- 2.42.0