Discourage developers from catching subclasses of SocketException.
We recently had a bug in Apache HTTP client where catching a
specific exception subclass caused incorrect behavior. Apache HTTP
expects a ConnectException but we're throwing its superclass,
SocketException. Unfortunately I don't think fixing this to throw
ConnectException is any better; the best I can tell from the spec
this should be throwing a NoRouteToHostException which would still
fail on Apache HTTP client. I'm going to fix that code to catch the
appropriate type.
Bug: http://b/5293809
Bug: http://b/4411922
Change-Id: I189408f6e2355475510fb817c97017e7bae1739e
6 files changed