I'm currently making a multi-threaded server, and i'm having trouble, while
inside a created thread to a specific client, in detect when the client disconnects.
For example:

I forced socket.close() and then asked for the client inetaddress (socket.getInetAddress())
and it's replyed the correct client address, my question is:

If the socket is already closed why is not retrivied something like null
or -1, so that i could detect the disconnected client?

Besides sending a message to the client and then try to cath Exception in
case the socket's already closed, is there any other way to do this?