diff options
Diffstat (limited to 'src/core/lib/surface/api_trace.h')
-rw-r--r-- | src/core/lib/surface/api_trace.h | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/core/lib/surface/api_trace.h b/src/core/lib/surface/api_trace.h index 105abdf629..a4e11ce154 100644 --- a/src/core/lib/surface/api_trace.h +++ b/src/core/lib/surface/api_trace.h @@ -22,11 +22,7 @@ #include <grpc/support/log.h> #include "src/core/lib/debug/trace.h" -#ifdef __cplusplus -extern "C" { -#endif - -extern grpc_tracer_flag grpc_api_trace; +extern grpc_core::TraceFlag grpc_api_trace; /* Provide unwrapping macros because we're in C89 and variadic macros weren't introduced until C99... */ @@ -47,12 +43,8 @@ extern grpc_tracer_flag grpc_api_trace; /* Due to the limitations of C89's preprocessor, the arity of the var-arg list 'nargs' must be specified. */ #define GRPC_API_TRACE(fmt, nargs, args) \ - if (GRPC_TRACER_ON(grpc_api_trace)) { \ + if (grpc_api_trace.enabled()) { \ gpr_log(GPR_INFO, fmt GRPC_API_TRACE_UNWRAP##nargs args); \ } -#ifdef __cplusplus -} -#endif - #endif /* GRPC_CORE_LIB_SURFACE_API_TRACE_H */ |