handle_connect called when connection fails
Thu, 26 Oct 2000 13:42:55 -0000
The following code tries to connect to a port that no one is listening
to - the problem is that handle_connect is called anyway. Is there
anyway I can find out whether the connection failed without trying to
write or read (which I imagined would fail).
class test (asyncore.dispatcher):
def __init__ (self):
def handle_connect (self):
if __name__ == '__main__':
t = test()
# there's nobody listening on 9879
Thanks in advance.