Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Watson2016-10-24 20:00:55 +0000
committerThomas Watson2016-11-07 20:19:26 +0000
commite71e4cbe7f8f7d813d890e522979a490d8f295ab (patch)
treee86ab2f1e71292b033ed687c3090ef4f73e97902 /bundles/org.eclipse.equinox.launcher
parentcc11dbcc759c5d04377bdb1a3b1c1ffe005f01ac (diff)
downloadrt.equinox.framework-e71e4cbe7f8f7d813d890e522979a490d8f295ab.tar.gz
rt.equinox.framework-e71e4cbe7f8f7d813d890e522979a490d8f295ab.tar.xz
rt.equinox.framework-e71e4cbe7f8f7d813d890e522979a490d8f295ab.zip
scenarios Change-Id: I2cf6b79d055eef7fb180f3f0f75032cbb84b7d51 Signed-off-by: Thomas Watson <tjwatson@us.ibm.com>
Diffstat (limited to 'bundles/org.eclipse.equinox.launcher')
-rw-r--r--bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java13
1 files changed, 12 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java b/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java
index 34bcf44d3..bbec0b646 100644
--- a/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java
+++ b/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java
@@ -2137,7 +2137,7 @@ public class Main {
Properties props = new Properties();
InputStream is = null;
try {
- is = url.openStream();
+ is = getStream(url);
props.load(is);
} finally {
if (is != null)
@@ -2150,6 +2150,17 @@ public class Main {
return props;
}
+ private InputStream getStream(URL location) throws IOException {
+ if ("file".equalsIgnoreCase(location.getProtocol())) { //$NON-NLS-1$
+ // this is done to handle URLs with invalid syntax in the path
+ File f = new File(location.getPath());
+ if (f.exists()) {
+ return new FileInputStream(f);
+ }
+ }
+ return location.openStream();
+ }
+
/*
* Handle splash screen.
* The splash screen is displayed natively. Whether or not the splash screen

Back to the top