From c0c7b0f86f9efb4667c87081c69fadcef83d0618 Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Sat, 4 May 2019 16:13:55 -0700 Subject: [PATCH] Make tsan detection gcc compatible --- src/topic_monitor.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/topic_monitor.cpp b/src/topic_monitor.cpp index 7818f56bb..a948f75bc 100644 --- a/src/topic_monitor.cpp +++ b/src/topic_monitor.cpp @@ -16,6 +16,9 @@ #define TOPIC_MONITOR_TSAN_WORKAROUND 1 #endif #endif +#if __SANITIZE_THREAD__ +#define TOPIC_MONITOR_TSAN_WORKAROUND 1 +#endif /// Implementation of the principal monitor. This uses new (and leaks) to avoid registering a /// pointless at-exit handler for the dtor.