about summary refs log tree commit diff
path: root/nis
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2017-04-19 07:45:04 +0200
committerFlorian Weimer <fweimer@redhat.com>2017-04-19 07:45:04 +0200
commit2f83a7294d0d0904d72839843a80531769525d59 (patch)
tree709774c38a94b5b99735121ce1e5979605fa0ce0 /nis
parente92030239abb4038d4f915d47021d6c037239309 (diff)
downloadglibc-2f83a7294d0d0904d72839843a80531769525d59.tar.gz
glibc-2f83a7294d0d0904d72839843a80531769525d59.tar.xz
glibc-2f83a7294d0d0904d72839843a80531769525d59.zip
Create more sockets with SOCK_CLOEXEC [BZ #15722]
Diffstat (limited to 'nis')
-rw-r--r--nis/nis_findserv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/nis/nis_findserv.c b/nis/nis_findserv.c
index 77f3c7c3ce..8e01164e3d 100644
--- a/nis/nis_findserv.c
+++ b/nis/nis_findserv.c
@@ -142,7 +142,7 @@ __nis_findfastest_with_timeout (dir_binding *bind,
     }
 
   /* Create RPC handle */
-  sock = socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP);
+  sock = socket (AF_INET, SOCK_DGRAM | SOCK_CLOEXEC, IPPROTO_UDP);
   clnt = clntudp_create (&saved_sin, NIS_PROG, NIS_VERSION, *timeout, &sock);
   if (clnt == NULL)
     {