Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVikas Chandra2015-10-17 11:29:10 +0000
committerVikas Chandra2015-10-17 11:29:10 +0000
commitc8079e8af76c30b7e875f3bab24048f4ddda8aed (patch)
treea9911332ca34567cee0959ef2c44444aa5eb5452
parenta76f991012fa0c22ad6b1223afbe9ec207912ecd (diff)
downloadeclipse.pde.ui-c8079e8af76c30b7e875f3bab24048f4ddda8aed.tar.gz
eclipse.pde.ui-c8079e8af76c30b7e875f3bab24048f4ddda8aed.tar.xz
eclipse.pde.ui-c8079e8af76c30b7e875f3bab24048f4ddda8aed.zip
Bug 472778 - Launch validation doesn't find plugin needed in twoI20151020-0800
versions
-rw-r--r--ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/launcher/BundleLauncherHelper.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/launcher/BundleLauncherHelper.java b/ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/launcher/BundleLauncherHelper.java
index 876ff69783..66908c27c6 100644
--- a/ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/launcher/BundleLauncherHelper.java
+++ b/ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/launcher/BundleLauncherHelper.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2007, 2013 IBM Corporation and others.
+ * Copyright (c) 2007, 2015 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -177,6 +177,7 @@ public class BundleLauncherHelper {
//remove conflicting duplicates - if they have same version or both are singleton
HashMap<String, IPluginModelBase> pluginMap = new HashMap<String, IPluginModelBase>();
+ Set<IPluginModelBase> pluginSet = new HashSet<IPluginModelBase>();
List<IPluginModelBase> workspaceModels = null;
for (Iterator<IPluginModelBase> iterator = launchPlugins.iterator(); iterator.hasNext();) {
IPluginModelBase model = iterator.next();
@@ -187,16 +188,17 @@ public class BundleLauncherHelper {
if (workspaceModels == null)
workspaceModels = Arrays.asList(PluginRegistry.getWorkspaceModels());
if (!workspaceModels.contains(existing)) { //if existing model is external
- pluginMap.put(id, model); // launch the workspace model
+ pluginSet.add(model);// launch the workspace model
continue;
}
}
}
- pluginMap.put(id, model);
+ pluginSet.add(model);
}
+ pluginMap.clear();
// Create the start levels for the selected plugins and add them to the map
- for (Iterator<IPluginModelBase> iterator = pluginMap.values().iterator(); iterator.hasNext();) {
+ for (Iterator<IPluginModelBase> iterator = pluginSet.iterator(); iterator.hasNext();) {
IPluginModelBase model = iterator.next();
addBundleToMap(map, model, "default:default"); //$NON-NLS-1$
}

Back to the top