aboutsummaryrefslogtreecommitdiffhomepage
path: root/third_party/cares
diff options
context:
space:
mode:
authorGravatar apolcyn <apolcyn@google.com>2017-06-16 19:18:55 -0700
committerGravatar GitHub <noreply@github.com>2017-06-16 19:18:55 -0700
commitb6c44d42511b335aeb12ef02dce2041d8eed5b67 (patch)
treed6abeca1bb24b2ecfb3c7ff6a8dadeb897cab139 /third_party/cares
parent2f850801235580217bb74c5911686bce0374dcad (diff)
parent4616dd0685e954a3c617bdb14e73a19c93a85f89 (diff)
Merge pull request #11403 from apolcyn/remove_clock_gettime_calls
Avoid clock_gettime in cares, when grpc avoids it
Diffstat (limited to 'third_party/cares')
-rw-r--r--third_party/cares/config_linux/ares_config.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/third_party/cares/config_linux/ares_config.h b/third_party/cares/config_linux/ares_config.h
index 265974cfae..5be5010ed7 100644
--- a/third_party/cares/config_linux/ares_config.h
+++ b/third_party/cares/config_linux/ares_config.h
@@ -70,8 +70,14 @@
/* Define to 1 if bool is an available type. */
#define HAVE_BOOL_T 1
-/* Define to 1 if you have the clock_gettime function and monotonic timer. */
-#define HAVE_CLOCK_GETTIME_MONOTONIC 1
+/* Define HAVE_CLOCK_GETTIME_MONOTONIC to 1 if you have the clock_gettime
+ * function and monotonic timer.
+ *
+ * Note: setting HAVE_CLOCK_GETTIME_MONOTONIC causes use of the clock_gettime
+ * function from glibc, don't set it to support glibc < 2.17 */
+#ifndef GPR_BACKWARDS_COMPATIBILITY_MODE
+ #define HAVE_CLOCK_GETTIME_MONOTONIC 1
+#endif
/* Define to 1 if you have the closesocket function. */
/* #undef HAVE_CLOSESOCKET */