From 4dd4746437380f7971398dd4c6bb12cd5df112f3 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 8 Oct 2009 23:26:05 -0700 Subject: thread_spawn: trap EAGAIN on accept_nonblock EAGAIN is common on accept_nonblock with multiple processes sharing the same listen descriptors. oops :x --- lib/rainbows/thread_spawn.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/rainbows/thread_spawn.rb') diff --git a/lib/rainbows/thread_spawn.rb b/lib/rainbows/thread_spawn.rb index 613a3f0..35a575e 100644 --- a/lib/rainbows/thread_spawn.rb +++ b/lib/rainbows/thread_spawn.rb @@ -42,7 +42,7 @@ module Rainbows end c = begin l.accept_nonblock - rescue Errno::EINTR, Errno::ECONNABORTED + rescue Errno::EAGAIN, Errno::EINTR, Errno::ECONNABORTED next end threads.add(Thread.new(c) { |c| process_client(c) }) -- cgit v1.2.3-24-ge0c7