Catch socket timeout as well