From 3d89b4a8a862bae2e33beb3233d64a3eee461822 Mon Sep 17 00:00:00 2001 From: knu Date: Tue, 6 Mar 2007 09:59:25 +0000 Subject: * lib/shell/process-controller.rb: fix thread synchronization problem for [ruby-dev:30477]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@12006 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ lib/shell/process-controller.rb | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2730acfdde..a0d4574bc3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Mar 6 18:58:37 2007 Keiju Ishitsuka + + * lib/shell/process-controller.rb: fix thread synchronization + problem for [ruby-dev:30477]. + Tue Mar 6 18:44:26 2007 Akinori MUSHA * ext/digest/lib/md5.rb (MD5::new, MD5::md5): Catch up with diff --git a/lib/shell/process-controller.rb b/lib/shell/process-controller.rb index f74abfd686..8929805506 100644 --- a/lib/shell/process-controller.rb +++ b/lib/shell/process-controller.rb @@ -246,9 +246,11 @@ class Shell redo end Thread.exclusive do - terminate_job(command) - @job_condition.signal - command.notify "job(%id) finish.", @shell.debug? + @job_monitor.synchronize do + terminate_job(command) + @job_condition.signal + command.notify "job(%id) finish.", @shell.debug? + end end end } -- cgit v1.2.3