summaryrefslogtreecommitdiff
path: root/Lib/asyncore.py
diff options
context:
space:
mode:
authorJosiah Carlson <josiah.carlson@gmail.com>2008-07-07 05:04:12 +0000
committerJosiah Carlson <josiah.carlson@gmail.com>2008-07-07 05:04:12 +0000
commit1c6a1c7758b62f8ee75527835fd8322cbab79f1c (patch)
treede3bb175a29b954c8b2354eb7183bc260806bbaf /Lib/asyncore.py
parent5c155098a0f9cac476ac50100514fd2a7d192116 (diff)
downloadcpython-1c6a1c7758b62f8ee75527835fd8322cbab79f1c.tar.gz
Fixed bugs 760475, 953599, and 1519. This is a translation of changelist 64768
to the py3k branch.
Diffstat (limited to 'Lib/asyncore.py')
-rw-r--r--Lib/asyncore.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/Lib/asyncore.py b/Lib/asyncore.py
index e82d24bf4f..586358cff1 100644
--- a/Lib/asyncore.py
+++ b/Lib/asyncore.py
@@ -98,8 +98,10 @@ def readwrite(obj, flags):
obj.handle_read_event()
if flags & select.POLLOUT:
obj.handle_write_event()
- if flags & (select.POLLERR | select.POLLHUP | select.POLLNVAL):
+ if flags & (select.POLLERR | select.POLLNVAL):
obj.handle_expt_event()
+ if flags & select.POLLHUP:
+ obj.handle_close_event()
except (ExitNow, KeyboardInterrupt, SystemExit):
raise
except:
@@ -466,7 +468,7 @@ class dispatcher:
),
'error'
)
- self.close()
+ self.handle_close()
def handle_expt(self):
self.log_info('unhandled exception', 'warning')