From 6c4ff122ac7b1c3fd49e03170b265f1c6318de35 Mon Sep 17 00:00:00 2001 From: Peter Osterlund Date: Sat, 10 Aug 2019 18:10:14 +0200 Subject: [PATCH] Handle IllegalArgumentException thrown from openInputStream() --- DroidFishApp/src/main/java/org/petero/droidfish/DroidFish.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DroidFishApp/src/main/java/org/petero/droidfish/DroidFish.java b/DroidFishApp/src/main/java/org/petero/droidfish/DroidFish.java index de3eed9..9c68649 100644 --- a/DroidFishApp/src/main/java/org/petero/droidfish/DroidFish.java +++ b/DroidFishApp/src/main/java/org/petero/droidfish/DroidFish.java @@ -818,7 +818,7 @@ public class DroidFish extends Activity } } catch (IOException e) { DroidFishApp.toast(R.string.failed_to_read_pgn_data, Toast.LENGTH_SHORT); - } catch (SecurityException e) { + } catch (SecurityException|IllegalArgumentException e) { DroidFishApp.toast(e.getMessage(), Toast.LENGTH_LONG); } return new Pair<>(pgnOrFen,filename);