Sebastian Lackner : server: Don't call close() on uninitialized memory in sock_check_pollhup.

Alexandre Julliard julliard at winehq.org
Wed Jan 1 14:24:22 CST 2014


Module: wine
Branch: master
Commit: 0b261bef76b038a6ab70f84d499e9da3ad3fd574
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=0b261bef76b038a6ab70f84d499e9da3ad3fd574

Author: Sebastian Lackner <sebastian at fds-team.de>
Date:   Tue Dec 31 17:50:56 2013 +0100

server: Don't call close() on uninitialized memory in sock_check_pollhup.

---

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

diff --git a/server/sock.c b/server/sock.c
index 1a3a8f7..5ffb1fe 100644
--- a/server/sock.c
+++ b/server/sock.c
@@ -194,7 +194,7 @@ static sock_shutdown_t sock_check_pollhup(void)
     struct pollfd pfd;
     char dummy;
 
-    if ( socketpair( AF_UNIX, SOCK_STREAM, 0, fd ) ) goto out;
+    if ( socketpair( AF_UNIX, SOCK_STREAM, 0, fd ) ) return ret;
     if ( shutdown( fd[0], 1 ) ) goto out;
 
     pfd.fd = fd[1];




More information about the wine-cvs mailing list