mirror of
https://sourceware.org/git/glibc.git
synced 2024-12-22 10:50:07 +00:00
* nscd/nscd_helper.c (get_mapping): Use MSG_CMSG_CLOEXEC for
descriptor received from nscd.
This commit is contained in:
parent
acf79996d4
commit
dde0763af5
@ -1,5 +1,8 @@
|
||||
2007-07-21 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* nscd/nscd_helper.c (get_mapping): Use MSG_CMSG_CLOEXEC for
|
||||
descriptor received from nscd.
|
||||
|
||||
* sysdeps/unix/sysv/linux/bits/socket.h: Define MSG_CMSG_CLOEXEC.
|
||||
|
||||
* sysdeps/unix/sysv/linux/i386/bits/fcntl.h: Define O_CLOEXEC.
|
||||
|
@ -265,7 +265,11 @@ get_mapping (request_type type, const char *key,
|
||||
if (wait_on_socket (sock) <= 0)
|
||||
goto out_close2;
|
||||
|
||||
if (__builtin_expect (TEMP_FAILURE_RETRY (__recvmsg (sock, &msg, 0))
|
||||
# ifndef MSG_CMSG_CLOEXEC
|
||||
# define MSG_CMSG_CLOEXEC 0
|
||||
# endif
|
||||
if (__builtin_expect (TEMP_FAILURE_RETRY (__recvmsg (sock, &msg,
|
||||
MSG_CMSG_CLOEXEC))
|
||||
!= keylen, 0))
|
||||
goto out_close2;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user