[Twisted-Python] socket is not closed when connection failed

Yun Mao maoy at cis.upenn.edu
Wed Feb 16 15:35:15 EST 2005

Hi everyone,

   I found that if a TCP connection is failed, e.g. UserTimeout or No route 
to host, connection refused, etc, i.e. when factory.ConnectionFailed is 
called, the socket is not properly cleaned up. i.e. socket.close() wasn't 
called. In this case, when I try to connect to many unreachable hosts, my 
file descriptor will finally be gone.

Could someone confirm me on this?  Thanks. I'm using twisted 1.3.0rc1


More information about the Twisted-Python mailing list