Check if socket resource has been lost