if len(self.events) > 0: timeout = 0
while True:
(r, _, _) = select([self.rfh], [], [], timeout)
if r:
self.get_response(async = True)
if len(self.events) > 0: timeout = 0
while True:
(r, _, _) = select([self.rfh], [], [], timeout)
if r:
self.get_response(async = True)