diff options
-rw-r--r-- | Lib/test/test_threading.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_threading.py b/Lib/test/test_threading.py index 0f3ac55..800d26f 100644 --- a/Lib/test/test_threading.py +++ b/Lib/test/test_threading.py @@ -1069,6 +1069,8 @@ class ThreadingExceptionTests(BaseTestCase): thread.join() self.assertIsNotNone(thread.exc) self.assertIsInstance(thread.exc, RuntimeError) + # explicitly break the reference cycle to not leak a dangling thread + thread.exc = None class TimerTests(BaseTestCase): |