Skip to content

Commit 13ccc5b

Browse files
committed
add repr to trigger the segfault, rephrase the NEWS
Signed-off-by: Keming <kemingy94@gmail.com>
1 parent cf1400f commit 13ccc5b

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Lib/test/test_set.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -701,6 +701,8 @@ def __eq__(self, value):
701701
self.assertEqual(len(tasks), 1)
702702
tasks.add(CorruptTrigger())
703703
self.assertEqual(len(tasks), 2)
704+
# cover the case in gh-141805 that triggers segfault
705+
repr(tasks)
704706

705707

706708
class SetSubclass(set):
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
Fix set length corruption when set additions occur within
2-
element comparison (:meth:`object.__eq__`) methods.
1+
Fix set corruption due to invalid length calculation when set additions occur
2+
in the element comparison (:meth:`object.__eq__`) methods.

0 commit comments

Comments
 (0)