diff options
author | Pascal Rapicault | 2010-12-17 01:36:34 +0000 |
---|---|---|
committer | Pascal Rapicault | 2010-12-17 01:36:34 +0000 |
commit | 58fc582de8d471a3759198ca79b9987f51703ab8 (patch) | |
tree | 929eb9f537209bb5f0a5674ceb7223205fba78cd /bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox | |
parent | 17355628ebe5f7baacd606187c6dd84b1d1c06b5 (diff) | |
download | rt.equinox.p2-58fc582de8d471a3759198ca79b9987f51703ab8.tar.gz rt.equinox.p2-58fc582de8d471a3759198ca79b9987f51703ab8.tar.xz rt.equinox.p2-58fc582de8d471a3759198ca79b9987f51703ab8.zip |
Bug 332655 - Setting IU properties for missing IUs in a profile dirties the profile but does not persist the propert
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox')
-rw-r--r-- | bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox/internal/p2/director/SimplePlanner.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox/internal/p2/director/SimplePlanner.java b/bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox/internal/p2/director/SimplePlanner.java index a42ac71c6..e8d6be1e7 100644 --- a/bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox/internal/p2/director/SimplePlanner.java +++ b/bundles/org.eclipse.equinox.p2.director/src/org/eclipse/equinox/internal/p2/director/SimplePlanner.java @@ -51,7 +51,7 @@ public class SimplePlanner implements IPlanner { private IProvisioningPlan generateProvisioningPlan(Collection<IInstallableUnit> fromState, Collection<IInstallableUnit> toState, ProfileChangeRequest changeRequest, IProvisioningPlan installerPlan, ProvisioningContext context) { IProvisioningPlan plan = engine.createPlan(changeRequest.getProfile(), context); planIUOperations(plan, fromState, toState); - planPropertyOperations(plan, changeRequest); + planPropertyOperations(plan, changeRequest, toState); if (DEBUG) { Object[] operands = new Object[0]; @@ -164,7 +164,7 @@ public class SimplePlanner implements IPlanner { return root; } - private void planPropertyOperations(IProvisioningPlan plan, ProfileChangeRequest profileChangeRequest) { + private void planPropertyOperations(IProvisioningPlan plan, ProfileChangeRequest profileChangeRequest, Collection<IInstallableUnit> toState) { // First deal with profile properties to remove. String[] toRemove = profileChangeRequest.getPropertiesToRemove(); @@ -181,6 +181,8 @@ public class SimplePlanner implements IPlanner { Map<IInstallableUnit, Map<String, String>> allIUPropertyChanges = profileChangeRequest.getInstallableUnitProfilePropertiesToAdd(); for (Map.Entry<IInstallableUnit, Map<String, String>> entry : allIUPropertyChanges.entrySet()) { IInstallableUnit iu = entry.getKey(); + if (!toState.contains(iu)) + continue; for (Map.Entry<String, String> entry2 : entry.getValue().entrySet()) { plan.setInstallableUnitProfileProperty(iu, entry2.getKey(), entry2.getValue()); } |