diff --git a/Lib/test/test_socket.py b/Lib/test/test_socket.py index 54fb9a1452a..c7a52d87a9a 100644 --- a/Lib/test/test_socket.py +++ b/Lib/test/test_socket.py @@ -1251,6 +1251,7 @@ class GeneralModuleTests(unittest.TestCase): signal.alarm(1) self.assertRaises(socket.timeout, c.sendall, b"x" * (1024**2)) finally: + signal.alarm(0) signal.signal(signal.SIGALRM, old_alarm) c.close() s.close()