specific exception for connection problems

This commit is contained in:
Pablo Fernandez committed 2012-04-28 21:03:11 -07:00
1 parent 3f4189607c
commit 8ceebf2ded
3 files changed
+18 -7

No files matched your search

+2 -6
View File
@@ -61,13 +61,9 @@ class Request
createConnection();
return doSend();
}
catch (UnknownHostException uhe)
catch (Exception e)
{
throw new OAuthException("Could not reach the desired host. Check your network connection.", uhe);
}
catch (IOException ioe)
{
throw new OAuthException("Problems while creating connection.", ioe);
throw new OAuthConnectionException(e);
}
}