--- a/cdt/cdt_6_0_x/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/BaseCElementContentProvider.java Wed Sep 09 12:47:57 2009 -0500
+++ b/cdt/cdt_6_0_x/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/BaseCElementContentProvider.java Thu Sep 10 14:08:35 2009 -0500
@@ -535,11 +535,17 @@
}
} catch (CModelException e) {
}
- if (objects == null || objects.length == 0) {
- return children;
+
+ Object[] result = children;
+ if (missingElements.size() > 0) {
+ result = concatenate(result, missingElements.toArray());
}
- Object[] result = concatenate(children, objects);
- return concatenate(result, missingElements.toArray());
+
+ if (objects != null && objects.length > 0) {
+ result = concatenate(result, objects);
+ }
+
+ return result;
}
private List<ICElement> getMissingElements(ICContainer container, ICElement[] elements) {