about summary refs log tree commit homepage
path: root/lib/dtas
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2014-10-21 01:11:28 +0000
committerEric Wong <e@80x24.org>2014-10-21 01:47:37 +0000
commit30ea437cce324fd92393e4cd4a4d6686ee514a75 (patch)
tree0d9325392183cbef2c767e700735dbf93631434a /lib/dtas
parent21760a43c3b650e2af09c183e457e38ad4bf05c0 (diff)
downloaddtas-30ea437cce324fd92393e4cd4a4d6686ee514a75.tar.gz
We only drop dead connections, not live ones.  This is noticeable
on my home machine when using the "powersave" CPU governor.
Diffstat (limited to 'lib/dtas')
-rw-r--r--lib/dtas/unix_accepted.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/dtas/unix_accepted.rb b/lib/dtas/unix_accepted.rb
index 491f45f..2c82d2a 100644
--- a/lib/dtas/unix_accepted.rb
+++ b/lib/dtas/unix_accepted.rb
@@ -57,6 +57,8 @@ class DTAS::UNIXAccepted # :nodoc:
     begin
       begin
         msg, _, _ = io.recvmsg_nonblock(nread)
+      rescue Errno::EAGAIN
+        return :wait_readable
       rescue EOFError, SystemCallError
         return nil
       end