harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nikolay Kuznetsov (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-1592) Thread interrupt and Thread.stop may not work properly if thread is waiting
Date Fri, 06 Oct 2006 22:10:20 GMT
     [ http://issues.apache.org/jira/browse/HARMONY-1592?page=all ]

Nikolay Kuznetsov updated HARMONY-1592:

    Attachment: Test.java

Sorry for the delay, I missed your comment somehow.

Attached test case demonstrates the problem. The idea of the test is simple:
Start two threads wich will wait on the same monitor, ensure that both threads 
are waiting and try to stop the one which began to wait later.

Currently the test will hang, while the valid output should be:
./java Test
Will start two threads which will wait on the same monitor
Both threads are waiting now, will stop second one
Thread was stopped, will notify waiting and exit

Thank you.

> Thread interrupt and Thread.stop may not work properly if thread is waiting
> ---------------------------------------------------------------------------
>                 Key: HARMONY-1592
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1592
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>            Reporter: Nikolay Kuznetsov
>         Attachments: stop_interrupt_waited.patch, Test.java
> Thread.interrupt and Thread.stop may not wake up a thread if it's waiting. The problem
here is that both hythread_stop and hythread_interrupt do
> hythread_notify instead of hythread_notify_all on current condition the thread is waiting
on, while this notification may not affect target thread.

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message