diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | resolv/res_send.c | 6 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/kernel-features.h | 2 |
3 files changed, 10 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog index 18934f1aa7..2e438ec77f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2008-12-07 Ulrich Drepper <drepper@redhat.com> + * resolv/res_send.c (send_dg): Use correct guards for SOCK_CLOEXEC + use. + + * sysdeps/unix/sysv/linux/kernel-features.h: Fix typo in accept4 + handling. + * resolv/res_init.c (__res_vinit): Always assign to statp->nscount after reading name server list. diff --git a/resolv/res_send.c b/resolv/res_send.c index ce4c11f144..f75a26ec23 100644 --- a/resolv/res_send.c +++ b/resolv/res_send.c @@ -104,7 +104,7 @@ static const char rcsid[] = "$BINDId: res_send.c,v 8.38 2000/03/30 20:16:51 vixi #endif -#ifndef __ASSUME_O_CLOEXEC +#ifndef __ASSUME_SOCK_CLOEXEC static int __have_o_nonblock; #else # define __have_o_nonblock 0 @@ -932,7 +932,7 @@ send_dg(res_state statp, EXT(statp).nssocks[ns] = socket(PF_INET6, SOCK_DGRAM|SOCK_NONBLOCK, 0); -#ifndef __ASSUME_O_CLOEXEC +#ifndef __ASSUME_SOCK_CLOEXEC if (__have_o_nonblock == 0) __have_o_nonblock = (EXT(statp).nssocks[ns] == -1 @@ -954,7 +954,7 @@ send_dg(res_state statp, EXT(statp).nssocks[ns] = socket(PF_INET, SOCK_DGRAM|SOCK_NONBLOCK, 0); -#ifndef __ASSUME_O_CLOEXEC +#ifndef __ASSUME_SOCK_CLOEXEC if (__have_o_nonblock == 0) __have_o_nonblock = (EXT(statp).nssocks[ns] == -1 diff --git a/sysdeps/unix/sysv/linux/kernel-features.h b/sysdeps/unix/sysv/linux/kernel-features.h index 900baf10c7..42b1c105a2 100644 --- a/sysdeps/unix/sysv/linux/kernel-features.h +++ b/sysdeps/unix/sysv/linux/kernel-features.h @@ -512,7 +512,7 @@ #endif /* Support for the accept4 syscall was added in 2.6.28. */ -#if __LINUX_KERNEL_VERSION >= 0x02061b \ +#if __LINUX_KERNEL_VERSION >= 0x02061c \ && (defined __i386__ || defined __x86_64__ || defined __powerpc__ \ || defined __ia64__ || defined __sparc__ || __s390__) # define __ASSUME_ACCEPT4 1 |