[New-bugs-announce] [issue11267] asyncore does not check for POLLERR and POLLHUP if neither readable nor writable

Марк Коренберг report at bugs.python.org
Mon Feb 21 06:54:32 CET 2011


New submission from Марк Коренберг <socketpair at gmail.com>:

asyncore.py: poll2() :
--------------------
if flags:
    # Only check for exceptions if object was either readable
    # or writable.
    flags |= select.POLLERR | select.POLLHUP | select.POLLNVAL
    pollster.register(fd, flags)
--------------------

This is unexpected behaviour. Why descriptor does not get polled if neither read nor write selected ? So I can not track dropping of connection if I do not want neither read nor write. I think "if flags:" should be removed.

----------
components: IO, Library (Lib)
messages: 128941
nosy: mmarkk
priority: normal
severity: normal
status: open
title: asyncore does not check for POLLERR and POLLHUP if neither readable nor writable
type: behavior
versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11267>
_______________________________________


More information about the New-bugs-announce mailing list