[Part of patch #909005] Set initial poll flags

This commit is contained in:
Andrew M. Kuchling 2004-03-21 19:50:09 +00:00
parent 68522b1895
commit 0ebbbe30f1

View File

@ -136,9 +136,9 @@ def poll2(timeout=0.0, map=None):
pollster = select.poll()
if map:
for fd, obj in map.items():
flags = 0
flags = select.POLLERR | select.POLLHUP | select.POLLNVAL
if obj.readable():
flags = select.POLLIN
flags = select.POLLIN | select.POLLPRI
if obj.writable():
flags = flags | select.POLLOUT
if flags: