summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorDino Viehland <dinoviehland@meta.com>2024-05-02 20:03:29 (GMT)
committerGitHub <noreply@github.com>2024-05-02 20:03:29 (GMT)
commite54b0c8a4ad6c6e958245eb3ea4ecc47e0f97ff0 (patch)
tree7cc89e6f68cc7406f8c1f57e053832f7b5e31ed8 /Objects
parent1e67b9207c31a92d76bfac09fc706c4dc703669e (diff)
downloadcpython-e54b0c8a4ad6c6e958245eb3ea4ecc47e0f97ff0.zip
cpython-e54b0c8a4ad6c6e958245eb3ea4ecc47e0f97ff0.tar.gz
cpython-e54b0c8a4ad6c6e958245eb3ea4ecc47e0f97ff0.tar.bz2
gh-118519: Fix empty weakref list check (#118520)
Fix empty list check
Diffstat (limited to 'Objects')
-rw-r--r--Objects/weakrefobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/weakrefobject.c b/Objects/weakrefobject.c
index 93c5fe3..88afaec 100644
--- a/Objects/weakrefobject.c
+++ b/Objects/weakrefobject.c
@@ -988,7 +988,7 @@ PyObject_ClearWeakRefs(PyObject *object)
}
list = GET_WEAKREFS_LISTPTR(object);
- if (FT_ATOMIC_LOAD_PTR(list) == NULL) {
+ if (FT_ATOMIC_LOAD_PTR(*list) == NULL) {
// Fast path for the common case
return;
}