Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bundles/org.eclipse.equinox.p2.updatesite/src/org/eclipse/equinox/internal/p2/updatesite/SiteXMLAction.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.p2.updatesite/src/org/eclipse/equinox/internal/p2/updatesite/SiteXMLAction.java b/bundles/org.eclipse.equinox.p2.updatesite/src/org/eclipse/equinox/internal/p2/updatesite/SiteXMLAction.java
index 9dbfd8ad0..d63a1aa34 100644
--- a/bundles/org.eclipse.equinox.p2.updatesite/src/org/eclipse/equinox/internal/p2/updatesite/SiteXMLAction.java
+++ b/bundles/org.eclipse.equinox.p2.updatesite/src/org/eclipse/equinox/internal/p2/updatesite/SiteXMLAction.java
@@ -320,8 +320,11 @@ public class SiteXMLAction extends AbstractPublisherAction {
for (int i = 0; i < features.length; i++) {
//add a mapping for each category this feature belongs to
String[] categoryNames = features[i].getCategoryNames();
- Set<SiteCategory> categories = new HashSet<SiteCategory>();
- mappings.put(features[i], categories);
+ Set<SiteCategory> categories = mappings.get(features[i]);
+ if (categories == null) {
+ categories = new HashSet<SiteCategory>();
+ mappings.put(features[i], categories);
+ }
for (int j = 0; j < categoryNames.length; j++) {
SiteCategory category = site.getCategory(categoryNames[j]);
if (category != null)

Back to the top