Author: ngie
Date: Sat Jan 30 17:54:18 2016
New Revision: 295079
URL: https://svnweb.freebsd.org/changeset/base/295079

Log:
  Fix the type for hw.ncpu, so sysctlbyname doesn't consistently fail on
  64-bit architectures where sizeof(int) != sizeof(size_t).
  
  MFC after: 1 week
  PR: 206758
  Reported by: Christoph Schönweiler <public2...@hauptsignal.at>
  Submitted by: kib
  Sponsored by: EMC / Isilon Storage Division

Modified:
  head/libexec/atrun/atrun.c

Modified: head/libexec/atrun/atrun.c
==============================================================================
--- head/libexec/atrun/atrun.c  Sat Jan 30 17:43:41 2016        (r295078)
+++ head/libexec/atrun/atrun.c  Sat Jan 30 17:54:18 2016        (r295079)
@@ -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
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to