From efe0b4b2ddf53bcee99a1645035300bdc800b02a Mon Sep 17 00:00:00 2001 From: Yash Tibrewal Date: Thu, 14 Mar 2019 12:04:05 -0700 Subject: [PATCH] Use GRPC_LINUX_ERRQUEUE --- src/core/lib/iomgr/internal_errqueue.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/core/lib/iomgr/internal_errqueue.cc b/src/core/lib/iomgr/internal_errqueue.cc index 982d709f094..4e2bfe3ccd5 100644 --- a/src/core/lib/iomgr/internal_errqueue.cc +++ b/src/core/lib/iomgr/internal_errqueue.cc @@ -38,8 +38,7 @@ bool kernel_supports_errqueue() { return errqueue_supported; } void grpc_errqueue_init() { /* Both-compile time and run-time linux kernel versions should be atleast 4.0.0 */ -#ifdef LINUX_VERSION_CODE -#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 0, 0) +#ifdef GRPC_LINUX_ERRQUEUE struct utsname buffer; if (uname(&buffer) != 0) { gpr_log(GPR_ERROR, "uname: %s", strerror(errno)); @@ -55,8 +54,7 @@ void grpc_errqueue_init() { } else { gpr_log(GPR_DEBUG, "ERRQUEUE support not enabled"); } -#endif /* LINUX_VERSION_CODE <= KERNEL_VERSION(4, 0, 0) */ -#endif /* LINUX_VERSION_CODE */ +#endif /* GRPC_LINUX_ERRQUEUE */ } } /* namespace grpc_core */