Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ConcurrentModificationException in LaunchConfigurationManager.fireLaunchHistoryChanged #613

Closed
iloveeclipse opened this issue Aug 2, 2023 · 0 comments · Fixed by #614
Closed
Assignees
Labels
bug Something isn't working
Milestone

Comments

@iloveeclipse
Copy link
Member

iloveeclipse commented Aug 2, 2023

Error logged in one of our automated tests.
The code is trying to iterate over listeners and obviously one is added or removed at same time.

!ENTRY org.eclipse.debug.core 4 2 2023-07-31 00:33:18.912
!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.debug.core".
!STACK 0
java.util.ConcurrentModificationException
	at java.base/java.util.ArrayList$Itr.checkForComodification(ArrayList.java:1013)
	at java.base/java.util.ArrayList$Itr.next(ArrayList.java:967)
	at org.eclipse.debug.internal.ui.launchConfigurations.LaunchConfigurationManager.fireLaunchHistoryChanged(LaunchConfigurationManager.java:392)
	at org.eclipse.debug.internal.ui.launchConfigurations.LaunchHistory.fireLaunchHistoryChanged(LaunchHistory.java:148)
	at org.eclipse.debug.internal.ui.launchConfigurations.LaunchHistory.removeFavorite(LaunchHistory.java:420)
	at org.eclipse.debug.internal.ui.launchConfigurations.LaunchHistory.checkFavorites(LaunchHistory.java:401)
	at org.eclipse.debug.internal.ui.launchConfigurations.LaunchHistory.addHistory(LaunchHistory.java:121)
	at org.eclipse.debug.internal.ui.launchConfigurations.LaunchHistory.launchAdded(LaunchHistory.java:95)
	at org.eclipse.debug.internal.core.LaunchManager$LaunchNotifier.run(LaunchManager.java:425)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.debug.internal.core.LaunchManager$LaunchNotifier.notify(LaunchManager.java:415)
	at org.eclipse.debug.internal.core.LaunchManager.fireUpdate(LaunchManager.java:1046)
	at org.eclipse.debug.internal.core.LaunchManager.addLaunch(LaunchManager.java:693)
	at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:764)
	at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:717)
	at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:1040)
	at org.eclipse.debug.internal.ui.DebugUIPlugin.lambda$4(DebugUIPlugin.java:1099)
	at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)

I will push a patch in a moment

@iloveeclipse iloveeclipse added the bug Something isn't working label Aug 2, 2023
@iloveeclipse iloveeclipse self-assigned this Aug 2, 2023
@iloveeclipse iloveeclipse added this to the 4.29 M3 milestone Aug 2, 2023
iloveeclipse added a commit to iloveeclipse/eclipse.platform that referenced this issue Aug 2, 2023
One should use proper data structures to maintain a list of listeners.

Fixes eclipse-platform#613
iloveeclipse added a commit that referenced this issue Aug 2, 2023
One should use proper data structures to maintain a list of listeners.

Fixes #613
CodeLtDave pushed a commit to CodeLtDave/eclipse.platform that referenced this issue Aug 8, 2023
One should use proper data structures to maintain a list of listeners.

Fixes eclipse-platform#613
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant