delegate synchronize method
Delegate MonitorMixin#synchronize body to Monitor#synchronize. It makes guarantee interrupt safe (because Monitor#synchronize is written in C). I thought Ruby implementation is also safe, but I got stuck failure <http://ci.rvm.jp/results/trunk_test@P895/2327639> so that I introduce this fix to guarantee interrupt safe.
This commit is contained in:
parent
caac5f777a
commit
a0a3c70181
@ -205,12 +205,7 @@ module MonitorMixin
|
||||
# +MonitorMixin+.
|
||||
#
|
||||
def mon_synchronize(&b)
|
||||
@mon_data.enter
|
||||
begin
|
||||
yield
|
||||
ensure
|
||||
@mon_data.exit
|
||||
end
|
||||
@mon_data.synchronize(&b)
|
||||
end
|
||||
alias synchronize mon_synchronize
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user