vserver 2.0 rc7
[linux-2.6.git] / net / unix / garbage.c
index 3d5e1a5..4bd95c8 100644 (file)
@@ -100,7 +100,7 @@ static struct sock *unix_get_socket(struct file *filp)
        /*
         *      Socket ?
         */
-       if (inode->i_sock) {
+       if (S_ISSOCK(inode->i_mode)) {
                struct socket * sock = SOCKET_I(inode);
                struct sock * s = sock->sk;