Skip to content

Commit 366f32f

Browse files
committed
fix patch for newer grpc
Signed-off-by: mattip <[email protected]>
1 parent 518f441 commit 366f32f

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

thirdparty/patches/grpc-configurable-thread-count.patch

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
diff --git src/core/lib/gpr/linux/cpu.cc b/src/core/lib/gpr/linux/cpu.cc
2-
index 670ca6551c..043021dc4a 100644
3-
--- src/core/lib/gpr/linux/cpu.cc
4-
+++ src/core/lib/gpr/linux/cpu.cc
1+
diff --git src/core/util/linux/cpu.cc src/core/util/linux/cpu.cc
2+
--- src/core/util/linux/cpu.cc
3+
+++ src/core/util/linux/cpu.cc
54
@@ -24,6 +24,7 @@
65

76
#ifdef GPR_CPU_LINUX
@@ -10,7 +9,7 @@ index 670ca6551c..043021dc4a 100644
109
#include <errno.h>
1110
#include <sched.h>
1211
#include <string.h>
13-
@@ -49,7 +50,17 @@ static void init_num_cpus() {
12+
@@ -50,7 +51,17 @@ static void init_num_cpus() {
1413
#endif
1514
// This must be signed. sysconf returns -1 when the number cannot be
1615
// determined
@@ -27,5 +26,5 @@ index 670ca6551c..043021dc4a 100644
2726
+ ncpus = static_cast<int>(sysconf(_SC_NPROCESSORS_CONF));
2827
+ }
2928
if (ncpus < 1) {
30-
gpr_log(GPR_ERROR, "Cannot determine number of CPUs: assuming 1");
29+
LOG(ERROR) << "Cannot determine number of CPUs: assuming 1";
3130
ncpus = 1;

0 commit comments

Comments
 (0)