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 37040

Summary: Possible deadlock in nodes.
Product: platform Reporter: Petr Nejedly <pnejedly>
Component: NodesAssignee: Jaroslav Tulach <jtulach>
Status: VERIFIED FIXED    
Severity: blocker Keywords: THREAD
Priority: P2    
Version: 3.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Petr Nejedly 2003-11-05 09:01:41 UTC
updateChildren impl in FilterNode can still
potentially cause deadlock, if the children type
of the original Node is changed and then isLeaf is
called on the FilterNode, it calls setChildren and
tries to upgrade the Mutex from readAccess to
writeAccess, which is deadlock prone.
I've simulated it in the
FilterNodeTest.testIsLeafCanUpdateWhenAnotherThreadHoldsALock
Uncomment the test and try it.
Comment 1 Jaroslav Tulach 2003-11-05 12:21:24 UTC
Checking in src/org/openide/nodes/FilterNode.java;
/cvs/openide/src/org/openide/nodes/FilterNode.java,v  <--  FilterNode.java
new revision: 1.86; previous revision: 1.85
done
Processing log script arguments...
More commits to come...
Checking in test/unit/src/org/openide/nodes/FilterNodeTest.java;
/cvs/openide/test/unit/src/org/openide/nodes/FilterNodeTest.java,v 
<--  FilterNodeTest.java
new revision: 1.12; previous revision: 1.11
Comment 2 Petr Nejedly 2003-11-06 12:16:35 UTC
seems OK