I'm writing an FTP client (Perl 5.005_03) and I'm having problems with sockets in TIME_WAIT state. In know after closing a socket they have to hang around for a while, but if I run my app again straight after it exits then it hangs as the first socket it tries is still in TIME_WAIT. I'm looking for some way to determine the state of a returned socket before trying to use it.
Any thoughts?
Cheers,
Jimbo.
Any thoughts?
Cheers,
Jimbo.