1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-17 14:05:23 +02:00

[202109] Fixed a bug in the update modes cache which caused occasional invalid updates.

This commit is contained in:
Pawel Piech 2008-02-15 20:42:24 +00:00
parent d088dbc842
commit e83d9b7f35

View file

@ -325,10 +325,13 @@ public class DefaultVMContentProviderStrategy implements IElementContentProvider
// See https://bugs.eclipse.org/bugs/show_bug.cgi?id=202109 // See https://bugs.eclipse.org/bugs/show_bug.cgi?id=202109
// Instead of checking getStatus().isOK(), check getData() != null. // Instead of checking getStatus().isOK(), check getData() != null.
if (getData() != null) { if (getData() != null) {
for (int i = 0; i < elementsLength; i++) { for (int i = 0; i < elementsLength && i < getData().size(); i++) {
Object child = getData().get(i);
if (child != null) {
update.setChild(getData().get(i), elementsStartIdx + nodeStartIdx + i); update.setChild(getData().get(i), elementsStartIdx + nodeStartIdx + i);
} }
} }
}
elementsMultiRequestMon.requestMonitorDone(this); elementsMultiRequestMon.requestMonitorDone(this);
} }
})) }))