summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/sys/socket.h9
-rw-r--r--include/unistd.h7
2 files changed, 16 insertions, 0 deletions
diff --git a/include/sys/socket.h b/include/sys/socket.h
index 0824fc855..6037f92ae 100644
--- a/include/sys/socket.h
+++ b/include/sys/socket.h
@@ -227,6 +227,15 @@ extern int accept (int __fd, __SOCKADDR_ARG __addr,
socklen_t *__restrict __addr_len);
libc_hidden_proto(accept)
+#if defined __UCLIBC_LINUX_SPECIFIC__ && defined __USE_GNU
+/* Similar to 'accept' but takes an additional parameter to specify flags.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int accept4 (int __fd, __SOCKADDR_ARG __addr,
+ socklen_t *__restrict __addr_len, int __flags);
+#endif
+
/* Shut down all or part of the connection open on socket FD.
HOW determines what to shut down:
SHUT_RD = No more receptions;
diff --git a/include/unistd.h b/include/unistd.h
index c421cb308..956879003 100644
--- a/include/unistd.h
+++ b/include/unistd.h
@@ -389,6 +389,13 @@ extern ssize_t pwrite64 (int __fd, __const void *__buf, size_t __n,
extern int pipe (int __pipedes[2]) __THROW __wur;
libc_hidden_proto(pipe)
+#if defined __UCLIBC_LINUX_SPECIFIC__ && defined __USE_GNU
+/* Same as pipe but apply flags passed in FLAGS to the new file
+ descriptors. */
+extern int pipe2 (int __pipedes[2], int __flags) __THROW __wur;
+libc_hidden_proto(pipe2)
+#endif
+
/* Schedule an alarm. In SECONDS seconds, the process will get a SIGALRM.
If SECONDS is zero, any currently scheduled alarm will be cancelled.
The function returns the number of seconds remaining until the last