[SCM] Samba Shared Repository - branch v3-2-test updated - initial-v3-2-test-2471-gf7d2f69

Jeremy Allison jra at samba.org
Thu Feb 21 02:00:56 GMT 2008


The branch, v3-2-test has been updated
       via  f7d2f692994918037e603ef95dd097b03d2c5456 (commit)
      from  39eef8e86cfab60c1328d2335a737b41d8fd6db0 (commit)

http://gitweb.samba.org/?samba.git;a=shortlog;h=v3-2-test


- Log -----------------------------------------------------------------
commit f7d2f692994918037e603ef95dd097b03d2c5456
Author: Tim Potter <tpot at samba.org>
Date:   Mon Feb 18 10:43:46 2008 +1100

    Fix possible close of invalid fd if call to socket() returns -1.

-----------------------------------------------------------------------

Summary of changes:
 source/lib/util_sock.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/lib/util_sock.c b/source/lib/util_sock.c
index 71d48d6..e040f46 100644
--- a/source/lib/util_sock.c
+++ b/source/lib/util_sock.c
@@ -1933,7 +1933,8 @@ int create_pipe_sock(const char *socket_dir,
 
 out_close:
 	SAFE_FREE(path);
-	close(sock);
+	if (sock != -1)
+		close(sock);
 
 out_umask:
 	umask(old_umask);


-- 
Samba Shared Repository


More information about the samba-cvs mailing list