From: Jim Procter Date: Thu, 17 Sep 2020 11:09:42 +0000 (+0100) Subject: JAL-3750 parse protocol before checking if argument to -open can be opened as a file X-Git-Tag: Release_2_11_1_1~1^2~1 X-Git-Url: http://source.jalview.org/gitweb/?p=jalview.git;a=commitdiff_plain;h=dc26db3406f9e89a291d3f6c6faf2f6920d2035f JAL-3750 parse protocol before checking if argument to -open can be opened as a file --- diff --git a/src/jalview/bin/Jalview.java b/src/jalview/bin/Jalview.java index 341bcba..613cc02 100755 --- a/src/jalview/bin/Jalview.java +++ b/src/jalview/bin/Jalview.java @@ -451,7 +451,11 @@ public class Jalview } System.out.println("CMD [-open " + file + "] executed successfully!"); - if (!file.startsWith("http://")) + + + protocol = AppletFormatAdapter.checkProtocol(file); + + if (protocol == DataSourceType.FILE) { if (!(new File(file)).exists()) { @@ -463,8 +467,6 @@ public class Jalview } } - protocol = AppletFormatAdapter.checkProtocol(file); - try { format = new IdentifyFile().identify(file, protocol);