diff options
author | Vijay Pai <vpai@google.com> | 2018-03-05 06:11:18 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-05 06:11:18 -0800 |
commit | e5335b49ec35659c591bfbfb34825d181af5f4c3 (patch) | |
tree | 7dc07be8a099fc536f0b9a3b4e5302d3e88cd27f /src | |
parent | 0897bef6b0f8589eefa3f18444b1da58884c25d6 (diff) | |
parent | dca52e515c428f97d8c49c8eaad00e001b730a7d (diff) |
Merge pull request #14532 from ncteisen/cpu
Remain consistent with #14493
Diffstat (limited to 'src')
-rw-r--r-- | src/core/lib/gpr/cpu_posix.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/lib/gpr/cpu_posix.cc b/src/core/lib/gpr/cpu_posix.cc index 7a77f7ab64..915fd4976c 100644 --- a/src/core/lib/gpr/cpu_posix.cc +++ b/src/core/lib/gpr/cpu_posix.cc @@ -37,7 +37,7 @@ static long ncpus = 0; static pthread_key_t thread_id_key; static void init_ncpus() { - ncpus = sysconf(_SC_NPROCESSORS_ONLN); + ncpus = sysconf(_SC_NPROCESSORS_CONF); if (ncpus < 1 || ncpus > INT32_MAX) { gpr_log(GPR_ERROR, "Cannot determine number of CPUs: assuming 1"); ncpus = 1; |