Forum: Ruby-core [Closed] ConditionVariable may become inconsistent for interrupted threads

Posted by kosaki (Motohiro KOSAKI) (Guest)
on 2012-12-15 16:26
(Received via mailing list)
Issue #3212 has been updated by kosaki (Motohiro KOSAKI).

Tracker changed from Bug to Backport
Description updated
Status changed from Open to Closed

ConditionVariable @waiter issue was fixed at r38080.

----------------------------------------
Backport #3212: ConditionVariable may become inconsistent for 
interrupted threads
https://bugs.ruby-lang.org/issues/3212#change-34768

Author: sylvain.joyeux (Sylvain Joyeux)
Status: Closed
Priority: High
Assignee:
Category: core
Target version:


=begin
 While tracking another issue with ConditionVariable, I realized that 
ConditionVariable#wait assumes that the waking-up side (#signal and 
#broadcast) will remove the thread from the list of waiters.

 Unfortunately, Mutex#sleep may return right away if an interrupt is set 
for the thread, in which case the thread will stay in the condition 
variable's waiting list.
=end
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.