diff options
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/socketserver.py | 7 | ||||
-rw-r--r-- | Lib/test/test_sys.py | 2 |
2 files changed, 1 insertions, 8 deletions
diff --git a/Lib/socketserver.py b/Lib/socketserver.py index 37df2ba..e5f5778 100644 --- a/Lib/socketserver.py +++ b/Lib/socketserver.py @@ -445,12 +445,7 @@ class TCPServer(BaseServer): def close_request(self, request): """Called to clean up an individual request.""" - try: - #explicitly shutdown. socket.close() merely releases - #the socket and waits for GC to perform the actual close. - request.shutdown(socket.SHUT_WR) - except socket.error: - pass #some platforms may raise ENOTCONN here + request.shutdown(socket.SHUT_WR) request.close() diff --git a/Lib/test/test_sys.py b/Lib/test/test_sys.py index 8986741..cac90f4 100644 --- a/Lib/test/test_sys.py +++ b/Lib/test/test_sys.py @@ -182,8 +182,6 @@ class SysModuleTest(unittest.TestCase): "under Windows, test would generate a spurious crash dialog") code = textwrap.dedent(""" import sys - import msvcrt - msvcrt.SetErrorMode(msvcrt.SEM_FAILCRITICALERRORS) def f(): try: |