Skip to content

Commit e54b0c8

Browse files
authored
gh-118519: Fix empty weakref list check (#118520)
Fix empty list check
1 parent 1e67b92 commit e54b0c8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Objects/weakrefobject.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -988,7 +988,7 @@ PyObject_ClearWeakRefs(PyObject *object)
988988
}
989989

990990
list = GET_WEAKREFS_LISTPTR(object);
991-
if (FT_ATOMIC_LOAD_PTR(list) == NULL) {
991+
if (FT_ATOMIC_LOAD_PTR(*list) == NULL) {
992992
// Fast path for the common case
993993
return;
994994
}

0 commit comments

Comments
 (0)