add proper time-out for connections
Sending a keep-alive is not enough, as this may be buffered. There is no way to check if anything has been sent from the current host. So we need to check if nothing was received during twice the regular timeout interval. This way we know that a connection is stale.
Edited by Bernard van Gastel