Bugs item #771762, was opened at 2003-07-15 17:40
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=438935&aid=771762&group_id=44253
Category: Debugger
Group: Makes DrJ unstable
Status: Open
Resolution: None
Priority: 7
Submitted By: Charles Reis (csreis)
Assigned to: Charles Reis (csreis)
Summary: Deadlock in debugger/listeners
Initial Comment:
There is currently a race condition which can cause
deadlock in the debugger, because one thread has a lock
on the debugger and is trying to notify listeners, and
another thread has a lock on the EventNotifier and is
trying to call a synchronized method on the debugger.
(The debugger is synchronized for obvious threading
reasons, and the EventNotifier is synchronized so that
listeners cannot be added or removed while a
notification is in progress.)
This illustrates a much more serious problem. Any code
in a listener that calls a synchronized method on an
object can potentially cause deadlock, since a
different thread could already have the lock on that
object and could be attempting to notify listeners of
an event (thus attempting to acquire the EventNotifier
lock).
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=438935&aid=771762&group_id=44253
|