Don't run handler if it doesn't exist..
This commit is contained in:
1 parent
9c98a38604
commit
16f0bcc3ac
1 file changed
+2
-1
@@ -676,7 +676,8 @@ class PollIOLoop(IOLoop):
|
|||||||
while self._events:
|
while self._events:
|
||||||
fd, events = self._events.popitem()
|
fd, events = self._events.popitem()
|
||||||
try:
|
try:
|
||||||
self._handlers[fd](fd, events)
|
if self._handlers.has_key(fd):
|
||||||
|
self._handlers[fd](fd, events)
|
||||||
except (OSError, IOError) as e:
|
except (OSError, IOError) as e:
|
||||||
if e.args[0] == errno.EPIPE:
|
if e.args[0] == errno.EPIPE:
|
||||||
# Happens when the client closes the connection
|
# Happens when the client closes the connection
|
||||||
|
|||||||
Reference in new issue
Block a user