mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
ast DiffTree: don't drill down too deeply to avoid SOE (EA-128679)
This commit is contained in:
@@ -92,6 +92,10 @@ public class DiffTree<OT, NT> {
|
||||
|
||||
@NotNull
|
||||
private CompareResult build(@NotNull OT oldNode, @NotNull NT newNode, int level, @NotNull DiffTreeChangeBuilder<OT, NT> consumer) {
|
||||
if (level > 1000) {
|
||||
return CompareResult.NOT_EQUAL;
|
||||
}
|
||||
|
||||
if (level == myNewChildrenLists.size()) {
|
||||
myNewChildrenLists.add(new Ref<NT[]>());
|
||||
myOldChildrenLists.add(new Ref<OT[]>());
|
||||
|
||||
Reference in New Issue
Block a user