From 5c2189fdd7287619f8ef7cc9c0d8003d864b7a9a Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Sun, 5 Apr 2015 09:43:45 +0200 Subject: [PATCH] Added Exception to read of server list that shows local buffered list. --- .../src/main/java/mage/client/dialog/ConnectDialog.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Mage.Client/src/main/java/mage/client/dialog/ConnectDialog.java b/Mage.Client/src/main/java/mage/client/dialog/ConnectDialog.java index d8246a8a9d..c0da5bae33 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/ConnectDialog.java +++ b/Mage.Client/src/main/java/mage/client/dialog/ConnectDialog.java @@ -54,6 +54,7 @@ import java.io.InputStreamReader; import java.io.Writer; import java.net.InetSocketAddress; import java.net.Proxy; +import java.net.SocketTimeoutException; import java.net.URL; import java.net.UnknownHostException; import java.util.ArrayList; @@ -442,7 +443,7 @@ public class ConnectDialog extends MageDialog { boolean URLNotFound = false; try { in = new BufferedReader(new InputStreamReader(serverListURL.openConnection(p).getInputStream())); - } catch (FileNotFoundException| UnknownHostException ex ) { + } catch (SocketTimeoutException |FileNotFoundException | UnknownHostException ex ) { logger.warn("Could not read serverlist from: " + serverListURL.toString()); File f = new File("serverlist.txt"); if (f.exists() && !f.isDirectory()) {