about summary refs log tree commit homepage
path: root/lib/unicorn/socket.rb
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2009-03-21 22:46:34 -0700
committerEric Wong <normalperson@yhbt.net>2009-03-22 21:25:17 -0700
commit451a1022e16ec6307328125a41244a837c6edcdf (patch)
treeb80a8d2c6fc5c0369960e5b429e396ef5ff91705 /lib/unicorn/socket.rb
parent5d57a6f2525c3c1feea98d64e1caf2f32147cf7f (diff)
downloadunicorn-451a1022e16ec6307328125a41244a837c6edcdf.tar.gz
Since we always unlink existing sockets when binding, there's no
point in having code to unlink the sockets when we exit.
Additionally, the old code path was racy.
Diffstat (limited to 'lib/unicorn/socket.rb')
-rw-r--r--lib/unicorn/socket.rb7
1 files changed, 0 insertions, 7 deletions
diff --git a/lib/unicorn/socket.rb b/lib/unicorn/socket.rb
index 4913261..9519448 100644
--- a/lib/unicorn/socket.rb
+++ b/lib/unicorn/socket.rb
@@ -62,13 +62,6 @@ module Unicorn
       end
     end
 
-    def destroy_safely(io)
-      if io.respond_to?(:path) && File.stat(io.path).ino == io.stat.ino
-        File.unlink(io.path) rescue nil
-      end
-      io.close rescue nil
-    end
-
     # creates a new server, socket. address may be a HOST:PORT or
     # an absolute path to a UNIX socket.  address can even be a Socket
     # object in which case it is immediately returned