This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 255997 - [mixeddev] ConcurrentModificationException in NativeDebuggerManager.notifyAttached
Summary: [mixeddev] ConcurrentModificationException in NativeDebuggerManager.notifyAtt...
Status: VERIFIED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Debugger (show other bugs)
Version: 8.1
Hardware: All All
: P3 normal (vote)
Assignee: henk89
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-18 12:29 UTC by Vladimir Kvashin
Modified: 2016-03-16 08:12 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Possible fix (designed together with Nikolay) (4.16 KB, patch)
2015-10-19 17:13 UTC, Vladimir Kvashin
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Kvashin 2015-10-18 12:29:37 UTC
I don't remember exactly what I did, unfortunately.
But the collection NativeDebuggerManager.debuggerStateListeners is not synchronized at all, so we are doomed to get it from time to time.

java.util.ConcurrentModificationException
    at java.util.HashMap$HashIterator.nextNode(HashMap.java:1429)
    at java.util.HashMap$KeyIterator.next(HashMap.java:1453)
    at org.netbeans.modules.cnd.debugger.common2.debugger.NativeDebuggerManager.notifyAttached(NativeDebuggerManager.java:2291)
    at org.netbeans.modules.cnd.debugger.common2.debugger.DebuggerSettingsBridge.noteAttached(DebuggerSettingsBridge.java:491)
    at org.netbeans.modules.cnd.debugger.gdb2.GdbDebuggerSettingsBridge.noteAttached(GdbDebuggerSettingsBridge.java:172)
    at org.netbeans.modules.cnd.debugger.gdb2.GdbDebuggerImpl.attachDone(GdbDebuggerImpl.java:947)
    at org.netbeans.modules.cnd.debugger.gdb2.GdbDebuggerImpl.access$1400(GdbDebuggerImpl.java:141)
    at org.netbeans.modules.cnd.debugger.gdb2.GdbDebuggerImpl$9.onDone(GdbDebuggerImpl.java:926)
    at org.netbeans.modules.cnd.debugger.gdb2.mi.MICommandManager.dispatch(MICommandManager.java:194)
    at org.netbeans.modules.cnd.debugger.gdb2.mi.MIProxy.dispatch(MIProxy.java:188)
    at org.netbeans.modules.cnd.debugger.gdb2.Gdb$MyMIProxy.dispatch(Gdb.java:697)
    at org.netbeans.modules.cnd.debugger.gdb2.mi.MIProxy.result(MIProxy.java:193)
    at org.netbeans.modules.cnd.debugger.gdb2.mi.MIProxy.processLine(MIProxy.java:157)
    at org.netbeans.modules.cnd.debugger.gdb2.Tap$4.run(Tap.java:327)
Caused: java.lang.Exception: when processing line: 14^done
    at org.netbeans.modules.cnd.debugger.gdb2.Tap$4.run(Tap.java:329)
    at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443)
    at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68)
    at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303)
    at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)
Comment 1 Vladimir Kvashin 2015-10-19 17:13:39 UTC
Created attachment 156808 [details]
Possible fix (designed together with Nikolay)
Comment 2 henk89 2015-10-20 09:43:22 UTC
Fixed in:
enum:7c2d6e609d4b

The patch proposed has been applied
Comment 3 Quality Engineering 2015-10-29 02:23:00 UTC
Integrated into 'main-silver', will be available in build *201510290002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/bbc5be8ce9d2
User: Nikolay Koldunov <henk89@netbeans.org>
Log: Fixed #255997 - [mixeddev] ConcurrentModificationException in NativeDebuggerManager.notifyAttached
(transplanted from 7c2d6e609d4be84f490a36636ae4e4f85ea67134)
Comment 4 Alexander Pepin 2015-11-27 16:31:48 UTC
Cannot reproduce the issue in build 20151119.