diff options
author | Krzysztof Daniel | 2012-03-08 13:58:33 +0000 |
---|---|---|
committer | Thomas Watson | 2012-03-08 13:58:33 +0000 |
commit | e545f5e1428338ed3c28686ee22186898eca0a55 (patch) | |
tree | 96f27914d44acee88f4c66701c7c7a84d4eddc8e | |
parent | 47f021c0ec945529add384c6b2d153caf027792d (diff) | |
download | rt.equinox.framework-e545f5e1428338ed3c28686ee22186898eca0a55.tar.gz rt.equinox.framework-e545f5e1428338ed3c28686ee22186898eca0a55.tar.xz rt.equinox.framework-e545f5e1428338ed3c28686ee22186898eca0a55.zip |
The loadConfiguration method is allowed to return null, so the
substituteVars(Properties) invoked as a last instruction inside the
loadConfiguration method must be able to handle null properties
properly.
-rw-r--r-- | bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java | 5 | ||||
-rw-r--r-- | bundles/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java | 4 |
2 files changed, 9 insertions, 0 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 fe2bf1ebb..6a51e42bf 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 @@ -8,6 +8,7 @@ * Contributors: * IBM Corporation - initial API and implementation * Anton Leherbauer (Wind River Systems) - bug 301226 + * Red Hat Inc. - bug 373640 *******************************************************************************/ package org.eclipse.equinox.launcher; @@ -2704,6 +2705,10 @@ public class Main { } private Properties substituteVars(Properties result) { + if (result == null) { + //nothing todo. + return null; + } for (Enumeration eKeys = result.keys(); eKeys.hasMoreElements();) { Object key = eKeys.nextElement(); if (key instanceof String) { diff --git a/bundles/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java b/bundles/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java index 9c2f824d7..5783d5a9e 100644 --- a/bundles/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java +++ b/bundles/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java @@ -1159,6 +1159,10 @@ public class EclipseStarter { } private static Properties substituteVars(Properties result) { + if (result == null) { + //nothing todo. + return null; + } for (Enumeration<Object> eKeys = result.keys(); eKeys.hasMoreElements();) { Object key = eKeys.nextElement(); if (key instanceof String) { |