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.