gh-118534: Fix load of gil->locked (#118553)

This commit is contained in:
Sam Gross
2024-05-03 18:13:40 -04:00
committed by GitHub
parent 6d9e8e989e
commit 0e78a545e6

View File

@@ -224,7 +224,7 @@ drop_gil(PyInterpreterState *interp, PyThreadState *tstate)
return;
}
#endif
if (!_Py_atomic_load_ptr_relaxed(&gil->locked)) {
if (!_Py_atomic_load_int_relaxed(&gil->locked)) {
Py_FatalError("drop_gil: GIL is not locked");
}