From 98caf73c954a9d8d5b80b13f3ca4e02fee92d87d Mon Sep 17 00:00:00 2001 From: Marko Luukkainen Date: Thu, 6 Apr 2017 18:02:33 +0300 Subject: [PATCH] Fix introduced ConcurrentModficationException refs #7045 Change-Id: Ib93731f246193505ec1bddc4e38928312b11981d --- .../org/simantics/interop/update/editor/ModelUpdateEditor.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/org.simantics.interop.update/src/org/simantics/interop/update/editor/ModelUpdateEditor.java b/org.simantics.interop.update/src/org/simantics/interop/update/editor/ModelUpdateEditor.java index 0881a7b..4c17299 100644 --- a/org.simantics.interop.update/src/org/simantics/interop/update/editor/ModelUpdateEditor.java +++ b/org.simantics.interop.update/src/org/simantics/interop/update/editor/ModelUpdateEditor.java @@ -558,7 +558,8 @@ public abstract class ModelUpdateEditor extends Composite{ public void perform(WriteGraph graph) throws DatabaseException { Layer0Utils.addCommentMetadata(graph, "Apply selected model updates"); graph.markUndoPoint(); - for (Pair mod : updateList.getSelected()) { + HashSet> changes = new HashSet<>(updateList.getSelected()); + for (Pair mod : changes) { updateList.removeChange(mod); applyLiteralChange(graph, mod); } -- 2.45.1