diff --git a/third_party/grpc/src/core/support/log_linux.c b/third_party/grpc/src/core/support/log_linux.c index 93a0c1b4c6..367c92118e 100644 --- a/third_party/grpc/src/core/support/log_linux.c +++ b/third_party/grpc/src/core/support/log_linux.c @@ -54,7 +54,7 @@ #include #include -static long gettid(void) { return syscall(__NR_gettid); } +static long sys_gettid(void) { return syscall(__NR_gettid); } void gpr_log(const char *file, int line, gpr_log_severity severity, const char *format, ...) { @@ -95,7 +95,7 @@ void gpr_default_log(gpr_log_func_args *args) { gpr_asprintf(&prefix, "%s%s.%09d %7tu %s:%d]", gpr_log_severity_string(args->severity), time_buffer, - (int)(now.tv_nsec), gettid(), display_file, args->line); + (int)(now.tv_nsec), sys_gettid(), display_file, args->line); fprintf(stderr, "%-60s %s\n", prefix, args->message); gpr_free(prefix); diff --git a/third_party/grpc/src/core/support/log_posix.c b/third_party/grpc/src/core/support/log_posix.c index 3ff171f99c..f0420a7b3b 100644 --- a/third_party/grpc/src/core/support/log_posix.c +++ b/third_party/grpc/src/core/support/log_posix.c @@ -45,7 +45,7 @@ #include #include -static intptr_t gettid(void) { return (intptr_t)pthread_self(); } +static intptr_t sys_gettid(void) { return (intptr_t)pthread_self(); } void gpr_log(const char *file, int line, gpr_log_severity severity, const char *format, ...) { @@ -95,7 +95,7 @@ void gpr_default_log(gpr_log_func_args *args) { fprintf(stderr, "%s%s.%09d %7tu %s:%d] %s\n", gpr_log_severity_string(args->severity), time_buffer, - (int)(now.tv_nsec), gettid(), display_file, args->line, + (int)(now.tv_nsec), sys_gettid(), display_file, args->line, args->message); }