diff options
author | Sergey Galtsev <sergey.galtsev@mongodb.com> | 2021-02-24 15:47:04 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-02-24 17:26:57 +0000 |
commit | 686dc9a29c3444759d538c3e0055f66dba4031d9 (patch) | |
tree | f3b1e0d1202fab43b63e3099ba627f3b1a924588 | |
parent | b27c452ce1a4afdf8596956aed5387025cb0e1d7 (diff) | |
download | mongo-686dc9a29c3444759d538c3e0055f66dba4031d9.tar.gz |
SERVER-54737 disable TSAN race detection in setSignalOnCount
-rw-r--r-- | src/mongo/watchdog/watchdog_test.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/mongo/watchdog/watchdog_test.cpp b/src/mongo/watchdog/watchdog_test.cpp index 9c954c812bc..fe2654aee79 100644 --- a/src/mongo/watchdog/watchdog_test.cpp +++ b/src/mongo/watchdog/watchdog_test.cpp @@ -211,7 +211,14 @@ public: return "test"; } - void setSignalOnCount(int c) { +// Ignore data races in this function when running with TSAN, races are acceptable here +#if defined(__has_feature) +#if __has_feature(thread_sanitizer) + __attribute__((no_sanitize("thread"))) +#endif +#endif + void + setSignalOnCount(int c) { _wait = c; } |