From 45cff66cf63593695ff5324d3765d8a1a1125adf Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Thu, 24 Jul 2014 18:49:36 +0200 Subject: Issue #16133: The asynchat.async_chat.handle_read() method now ignores BlockingIOError exceptions. Initial patch written by Xavier de Gaye. Document also in asyncore documentation that recv() may raise BlockingIOError. --- Lib/asynchat.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Lib/asynchat.py') diff --git a/Lib/asynchat.py b/Lib/asynchat.py index 6e16891d43..14c152f059 100644 --- a/Lib/asynchat.py +++ b/Lib/asynchat.py @@ -115,6 +115,8 @@ class async_chat(asyncore.dispatcher): try: data = self.recv(self.ac_in_buffer_size) + except BlockingIOError: + return except OSError as why: self.handle_error() return -- cgit v1.2.1