This is the mail archive of the java-discuss@sourceware.cygnus.com mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Deadlock in 'initializeClass'


>>>>> "Matt" == Matt Welsh <mdw@cs.berkeley.edu> writes:

Matt> While another thread does the 'notify()' that the class has been
Matt> initialized, for some reason the other threads never wake up.

Matt> Any ideas?

Funnily enough, I noticed this morning that there were bugs in this
area.

Two possibilities for the bug:

1. In some places I noticed that the "state" field was set but no
notify() was done.

2. Some places call notify() after updating state and some call
notifyAll(). I suspect we want to use notifyAll() everywhere, but I
haven't really looked into it.

Tom

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]