mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-31 12:55:40 +02:00
Prevent error-popup for selection listeners, bug 243114.
This commit is contained in:
parent
02dd15386f
commit
7a212506c0
1 changed files with 10 additions and 1 deletions
|
@ -175,7 +175,16 @@ public class SelectionListenerWithASTManager {
|
||||||
listeners= fAstListeners.getListeners();
|
listeners= fAstListeners.getListeners();
|
||||||
}
|
}
|
||||||
for (int i= 0; i < listeners.length; i++) {
|
for (int i= 0; i < listeners.length; i++) {
|
||||||
((ISelectionListenerWithAST) listeners[i]).selectionChanged(fPart, selection, astRoot);
|
final Object l = listeners[i];
|
||||||
|
try {
|
||||||
|
((ISelectionListenerWithAST) l).selectionChanged(fPart, selection, astRoot);
|
||||||
|
} catch (RuntimeException e) {
|
||||||
|
CUIPlugin.log(e);
|
||||||
|
fAstListeners.remove(l);
|
||||||
|
} catch (OutOfMemoryError e) {
|
||||||
|
CUIPlugin.log(e);
|
||||||
|
fAstListeners.remove(l);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return Status.OK_STATUS;
|
return Status.OK_STATUS;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue