[PATCH] server: removed duplicate close of acceptfd (Coverity)

Marcus Meissner marcus at jet.franken.de
Wed Oct 10 03:06:55 CDT 2012


Hi,

If NULL is returned, create_anonymous_fd has already closed
acceptfd for us.

Ciao, Marcus
---
 server/sock.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/server/sock.c b/server/sock.c
index 7e4acd8..546b88a 100644
--- a/server/sock.c
+++ b/server/sock.c
@@ -761,7 +761,6 @@ static int accept_into_socket( struct sock *sock, struct sock *acceptsock )
         if (!(newfd = create_anonymous_fd( &sock_fd_ops, acceptfd, &acceptsock->obj,
                                             get_fd_options( acceptsock->fd ) )))
         {
-            close( acceptfd );
             return FALSE;
         }
     }
-- 
1.7.3.4




More information about the wine-patches mailing list