about summary refs log tree commit homepage
path: root/lib/rainbows/rev/core.rb
diff options
context:
space:
mode:
authorEric Wong <e@yhbt.net>2010-08-25 13:58:11 -0700
committerEric Wong <normalperson@yhbt.net>2010-08-26 08:47:36 +0000
commit47e1ee2d90161abf92ce14562bf508398fdfa6c9 (patch)
treed4fb816d9874ec0b0bdfd285e9ca10e4f17d0227 /lib/rainbows/rev/core.rb
parentbd3ed0b04f826b20cce83f9b77fc13c0eefd3902 (diff)
downloadrainbows-47e1ee2d90161abf92ce14562bf508398fdfa6c9.tar.gz
Trying to avoid adding singleton methods since it's too easily
accessible by the public and not needed by the general public.
This also allows us (or just Zbatery) to more easily add support
systems without FD_CLOEXEC or fcntl, and also to optimize
away a fcntl call for systems that inherit FD_CLOEXEC.
Diffstat (limited to 'lib/rainbows/rev/core.rb')
-rw-r--r--lib/rainbows/rev/core.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/rainbows/rev/core.rb b/lib/rainbows/rev/core.rb
index 9f7a1f0..9f20574 100644
--- a/lib/rainbows/rev/core.rb
+++ b/lib/rainbows/rev/core.rb
@@ -7,12 +7,13 @@ require 'rainbows/rev/heartbeat'
 module Rainbows
   module Rev
     class Server < ::Rev::IO
+      include Rainbows::Acceptor
       G = Rainbows::G
       # CL and MAX will be defined in the corresponding worker loop
 
       def on_readable
         return if CONN.size >= MAX
-        io = Rainbows.accept(@_io) and CL.new(io).attach(LOOP)
+        io = accept(@_io) and CL.new(io).attach(LOOP)
       end
     end # class Server