M
manuel aldana
i wrote a program where a client socket communicates with a server
socket in just one direction (i.e. i only use a server input stream from
a client).
apart from getting an IOException when writing to streams how do i know
from the view of the server that the client socket isn't running anymore
(shutdown from winXP or unplugging ethernet cable etc. etc.)?
tried to figure that out from catching other exception but no success.
no success in using Socket.isConnected() either. it seems to just test
if it was connected at the beginning.
maybe it is the only solution to establish another stream, where the
server pings the client every 10 seconds to know if it's still there??
thnx in advance!
socket in just one direction (i.e. i only use a server input stream from
a client).
apart from getting an IOException when writing to streams how do i know
from the view of the server that the client socket isn't running anymore
(shutdown from winXP or unplugging ethernet cable etc. etc.)?
tried to figure that out from catching other exception but no success.
no success in using Socket.isConnected() either. it seems to just test
if it was connected at the beginning.
maybe it is the only solution to establish another stream, where the
server pings the client every 10 seconds to know if it's still there??
thnx in advance!