mirror of
https://github.com/python/cpython.git
synced 2025-08-28 20:56:54 +00:00
[3.13] gh-117657: Avoid sem_clockwait
in TSAN (GH-119915) (#119992)
The `sem_clockwait` function is not currently instrumented, which leads
to false positives.
(cherry picked from commit 41c1cefbae
)
Co-authored-by: Sam Gross <colesbury@gmail.com>
This commit is contained in:
parent
6b10467fbc
commit
ca37034baa
2 changed files with 1 additions and 10 deletions
|
@ -119,7 +119,7 @@ _PySemaphore_PlatformWait(_PySemaphore *sema, PyTime_t timeout)
|
|||
if (timeout >= 0) {
|
||||
struct timespec ts;
|
||||
|
||||
#if defined(CLOCK_MONOTONIC) && defined(HAVE_SEM_CLOCKWAIT)
|
||||
#if defined(CLOCK_MONOTONIC) && defined(HAVE_SEM_CLOCKWAIT) && !defined(_Py_THREAD_SANITIZER)
|
||||
PyTime_t now;
|
||||
// silently ignore error: cannot report error to the caller
|
||||
(void)PyTime_MonotonicRaw(&now);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue