Skip to content
Snippets Groups Projects
Commit bcd82ec7 authored by Jan David Mol's avatar Jan David Mol
Browse files

Task #9678: Replace select.select by select.poll to support fd > 1024

parent 1183a660
No related branches found
No related tags found
No related merge requests found
......@@ -122,11 +122,13 @@ class JobSocketReceiver(SocketServer.ThreadingTCPServer):
# until the queue is empty, thereby avoiding the problem of falling
# out of the logger threads before all log messages have been handled.
def loop_in_thread():
poller = select.poll()
poller.register(self.socket.fileno(), select.POLLIN)
while True:
rd, wr, ex = select.select(
[self.socket.fileno()], [], [], self.timeout
)
if rd:
events = poller.poll(self.timeout)
if events:
self.handle_request()
elif self.abort:
break
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment