Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Loskutov2019-12-15 19:31:44 +0000
committerAndrey Loskutov2019-12-15 19:34:56 +0000
commit65645a5b2f04b0bf017080bdb53ef35b385965af (patch)
treea1f5095e17fbb5f8279c605ea4555a638e367292 /bundles/org.eclipse.swt/Eclipse SWT Accessibility
parent55b811aa14bbb3a35de7216fdf9793277b675e23 (diff)
downloadeclipse.platform.swt-65645a5b2f04b0bf017080bdb53ef35b385965af.tar.gz
eclipse.platform.swt-65645a5b2f04b0bf017080bdb53ef35b385965af.tar.xz
eclipse.platform.swt-65645a5b2f04b0bf017080bdb53ef35b385965af.zip
Bug 558339 - [win32] ConcurrentModificationException in
Accessible.lambda$0(Accessible.java:2140) Accessible.children of the parent is modified on Accessible.dispose() of the child. Have no idea if this legal or not, but the simple solution is to not iterate over the modifiable list on parent dispose. Change-Id: Ib32c62b77757ac88ab96b84462fec75ec5229d69 Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT Accessibility')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT Accessibility/win32/org/eclipse/swt/accessibility/Accessible.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/win32/org/eclipse/swt/accessibility/Accessible.java b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/win32/org/eclipse/swt/accessibility/Accessible.java
index aa97818110..9c54416141 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Accessibility/win32/org/eclipse/swt/accessibility/Accessible.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Accessibility/win32/org/eclipse/swt/accessibility/Accessible.java
@@ -2137,7 +2137,8 @@ public class Accessible {
osAccessible.item = item;
if (!found) {
item.addListener(SWT.Dispose, e -> {
- for (Accessible accChild : children) {
+ List<Accessible> list = new ArrayList<>(children);
+ for (Accessible accChild : list) {
if (accChild.item == item) {
accChild.dispose();
}

Back to the top