about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/accept.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv/linux/accept.c')
-rw-r--r--sysdeps/unix/sysv/linux/accept.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/unix/sysv/linux/accept.c b/sysdeps/unix/sysv/linux/accept.c
index 72d42a7d85..8b4fff084d 100644
--- a/sysdeps/unix/sysv/linux/accept.c
+++ b/sysdeps/unix/sysv/linux/accept.c
@@ -21,11 +21,17 @@
 
 #include <sysdep-cancel.h>
 #include <socketcall.h>
+#include <sys/syscall.h>
+#include <kernel-features.h>
 
 int
 __libc_accept (int fd, __SOCKADDR_ARG addr, socklen_t *len)
 {
+#ifdef __ASSUME_ACCEPT_SYSCALL
+  return SYSCALL_CANCEL (accept, fd, addr.__sockaddr__, len);
+#else
   return SOCKETCALL_CANCEL (accept, fd, addr.__sockaddr__, len);
+#endif
 }
 weak_alias (__libc_accept, accept)
 libc_hidden_def (accept)