about summary refs log tree commit homepage
path: root/lib/rainbows/xepoll_thread_spawn
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rainbows/xepoll_thread_spawn')
-rw-r--r--lib/rainbows/xepoll_thread_spawn/client.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/rainbows/xepoll_thread_spawn/client.rb b/lib/rainbows/xepoll_thread_spawn/client.rb
index bb1f324..9735f64 100644
--- a/lib/rainbows/xepoll_thread_spawn/client.rb
+++ b/lib/rainbows/xepoll_thread_spawn/client.rb
@@ -8,6 +8,7 @@ module Rainbows::XEpollThreadSpawn::Client
   max = Rainbows.server.worker_connections
   ACCEPTORS = Rainbows::HttpServer::LISTENERS.map do |sock|
     Thread.new do
+      sleep
       begin
         if io = sock.kgio_accept(Rainbows::Client)
           N.incr(0, 1)
@@ -39,6 +40,7 @@ module Rainbows::XEpollThreadSpawn::Client
   end
 
   def self.loop
+    ACCEPTORS.each { |thr| thr.run }
     begin
       EP.wait(nil, 1000) { |fl, obj| obj.epoll_run }
       expire