Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/Utils.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/Utils.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/Utils.java
index 6d9c9346d..9ecbe99ec 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/Utils.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/Utils.java
@@ -400,8 +400,11 @@ public class Utils {
resources.add(element);
isResource = true;
} else if (element instanceof ISynchronizeModelElement){
- resources.add(((ISynchronizeModelElement) element).getResource());
- isResource = true;
+ IResource resource = ((ISynchronizeModelElement) element).getResource();
+ if (resource != null) {
+ resources.add(resource);
+ isResource = true;
+ }
} else if (element instanceof ResourceMapping) {
try {
ResourceTraversal[] traversals = ((ResourceMapping)element).getTraversals(ResourceMappingContext.LOCAL_CONTEXT, null);

Back to the top