[issue7978] SocketServer doesn't handle syscall interruption

Vetoshkin Nikita report at bugs.python.org
Tue Mar 9 08:35:39 CET 2010


Vetoshkin Nikita <nikita.vetoshkin at gmail.com> added the comment:

Wrapping select in (taken from twisted sources) can help:
def untilConcludes(f, *a, **kw):
    while True:
        try:
            return f(*a, **kw)
        except (IOError, OSError), e:
            if e.args[0] == errno.EINTR:
                continue
            raise

----------

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


More information about the Python-bugs-list mailing list