diff options
author | kosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-11-30 18:55:18 +0000 |
---|---|---|
committer | kosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-11-30 18:55:18 +0000 |
commit | 028ca79f986448221361bf2e9c16ec9c3e3b734b (patch) | |
tree | be2d2c34b8d2db3435d6befe5d8ac06e7eb51854 | |
parent | 3357d88ada8ad44ecf267f5f2a1fb1df4e5cb8f4 (diff) | |
download | ruby-028ca79f986448221361bf2e9c16ec9c3e3b734b.tar.gz |
* lib/thread.rb (ConditionVariable#broadcast): s/RuntimeError/StandardError/
* lib/thread.rb (ConditionVariable#signal): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | lib/thread.rb | 4 |
2 files changed, 7 insertions, 2 deletions
@@ -1,3 +1,8 @@ +Sat Dec 1 03:38:04 2012 KOSAKI Motohiro <kosaki.motohiro@gmail.com> + + * lib/thread.rb (ConditionVariable#broadcast): s/RuntimeError/StandardError/ + * lib/thread.rb (ConditionVariable#signal): ditto. + Sat Dec 1 03:29:52 2012 KOSAKI Motohiro <kosaki.motohiro@gmail.com> * lib/thread.rb (SizedQueue#pop): rewrite by using ConditionVariable. diff --git a/lib/thread.rb b/lib/thread.rb index e3aeed19fe..47add67e89 100644 --- a/lib/thread.rb +++ b/lib/thread.rb @@ -84,7 +84,7 @@ class ConditionVariable # Wakes up the first thread in line waiting for this lock. # def signal - Thread.async_interrupt_timing(RuntimeError => :on_blocking) do + Thread.async_interrupt_timing(StandardError => :on_blocking) do begin t = @waiters_mutex.synchronize {@waiters.shift} t.run if t @@ -99,7 +99,7 @@ class ConditionVariable # Wakes up all threads waiting for this lock. # def broadcast - Thread.async_interrupt_timing(RuntimeError => :on_blocking) do + Thread.async_interrupt_timing(StandardError => :on_blocking) do waiters0 = nil @waiters_mutex.synchronize do waiters0 = @waiters.dup |