You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reported by: adrian.wyssmann
monitors.waitForMonitor(xxx) in a test case throws an IllegalMonitorStateException?
java.lang.IllegalMonitorStateException
at java.lang.Object.wait(Native Method)
at jsystem.framework.monitor.MonitorsManager.waitForMonitor(MonitorsManager.java:131)
In the source code MonitorsManager?.java the monitor object is synchronize.
public void waitForMonitor(Monitor monitor, long timeout) throws Exception {
...
synchronized (monitor) {
t.wait(timeout);
}
...
but the thread should be synchronized, as the wait() is done on the thread object
public void waitForMonitor(Monitor monitor, long timeout) throws Exception {
...
synchronized (t) {
t.wait(timeout);
}
The text was updated successfully, but these errors were encountered:
Reported by: adrian.wyssmann
monitors.waitForMonitor(xxx) in a test case throws an IllegalMonitorStateException?
java.lang.IllegalMonitorStateException
at java.lang.Object.wait(Native Method)
at jsystem.framework.monitor.MonitorsManager.waitForMonitor(MonitorsManager.java:131)
In the source code MonitorsManager?.java the monitor object is synchronize.
public void waitForMonitor(Monitor monitor, long timeout) throws Exception {
...
synchronized (monitor) {
t.wait(timeout);
}
...
but the thread should be synchronized, as the wait() is done on the thread object
public void waitForMonitor(Monitor monitor, long timeout) throws Exception {
...
synchronized (t) {
t.wait(timeout);
}
The text was updated successfully, but these errors were encountered: