The problem I'm running into is that I need to determine how connect() failed. In other words, I need to know if the remote host acknowledged with FIN causing the connection to fail or if there was no response at all.
I believe that if connect() blocks, then the remote host did not respond; however, if the remote host responds with FIN, the socket will still not be connected, but connect should return anyway (and possibly throw an IOException?).
The java API is pretty skimpy on this, and I've not been able to find the answer to this anywhere else.
Thanks in advance.
-Chris
p.s. I've never looked for this, but does java have the equivilant of a raw socket? That would solve my problem as well(by compicating it ), and could be handy anyway.
[ December 24, 2008: Message edited by: Chris Blades ]
I believe that if connect() blocks, then the remote host did not respond; however, if the remote host responds with FIN, the socket will still not be connected, but connect should return anyway (and possibly throw an IOException?).
The java API is pretty skimpy on this, and I've not been able to find the answer to this anywhere else.
Thanks in advance.
-Chris
p.s. I've never looked for this, but does java have the equivilant of a raw socket? That would solve my problem as well(by compicating it ), and could be handy anyway.
[ December 24, 2008: Message edited by: Chris Blades ]