summaryrefslogtreecommitdiff
path: root/include/poll.h
diff options
context:
space:
mode:
authorTrutz Behn2015-03-14 20:06:48 +0100
committersin2015-03-14 20:37:27 +0000
commit22e7e51007f3a28ded43f6cb8f0ff59a7a691175 (patch)
tree3d2ca7e61136adc3f77b817e117699918e0c223a /include/poll.h
parentc2c9d0c6c8a1d74f748aa2ad9442957a37091062 (diff)
Use __typeof__ to in part avoid replicating function types
Diffstat (limited to 'include/poll.h')
-rw-r--r--include/poll.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/include/poll.h b/include/poll.h
index 05228b8..d00d7c1 100644
--- a/include/poll.h
+++ b/include/poll.h
@@ -11,8 +11,7 @@ extern "C" {
11 11
12#undef poll 12#undef poll
13 13
14extern int __poll_orig(struct pollfd *, nfds_t, int) 14__typeof__(poll) __poll_orig __asm__(__USER_LABEL_PREFIX__ "poll");
15 __asm__(__USER_LABEL_PREFIX__ "poll");
16extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__)) 15extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__))
17int poll(struct pollfd *fds, nfds_t nfds, int timeout) 16int poll(struct pollfd *fds, nfds_t nfds, int timeout)
18{ 17{
@@ -25,8 +24,7 @@ int poll(struct pollfd *fds, nfds_t nfds, int timeout)
25 24
26#ifdef _GNU_SOURCE 25#ifdef _GNU_SOURCE
27#undef ppoll 26#undef ppoll
28extern int __ppoll_orig(struct pollfd *, nfds_t, const struct timespec *, const sigset_t *) 27__typeof__(ppoll) __ppoll_orig __asm__(__USER_LABEL_PREFIX__ "ppoll");
29 __asm__(__USER_LABEL_PREFIX__ "ppoll");
30extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__)) 28extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__))
31int ppoll(struct pollfd *fds, nfds_t nfds, const struct timespec *timeout, const sigset_t *mask) 29int ppoll(struct pollfd *fds, nfds_t nfds, const struct timespec *timeout, const sigset_t *mask)
32{ 30{