summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common/ppoll.c
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2009-01-28 23:42:01 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2009-01-28 23:42:01 +0000
commitf82635e74a7e174f71f955eaa4f5dc788e596cc0 (patch)
tree1fbfef8211b35db62e6b544b1aca2a1bfa0323f8 /libc/sysdeps/linux/common/ppoll.c
parent317964651ced8ba016841cfe015e3ae09831b5c8 (diff)
fix ppoll. we forgot to pass 5th parameter to the syscall
Diffstat (limited to 'libc/sysdeps/linux/common/ppoll.c')
-rw-r--r--libc/sysdeps/linux/common/ppoll.c31
1 files changed, 17 insertions, 14 deletions
diff --git a/libc/sysdeps/linux/common/ppoll.c b/libc/sysdeps/linux/common/ppoll.c
index edcb1dc66..d550ae855 100644
--- a/libc/sysdeps/linux/common/ppoll.c
+++ b/libc/sysdeps/linux/common/ppoll.c
@@ -17,6 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#include <signal.h>
#include <sys/syscall.h>
#include <sys/poll.h>
@@ -26,24 +27,26 @@
# define __NR___libc_ppoll __NR_ppoll
static __always_inline
-_syscall4(int, __libc_ppoll, struct pollfd *, fds,
- nfds_t, nfds, const struct timespec *, timeout,
- const __sigset_t *, sigmask)
+_syscall5(int, __libc_ppoll,
+ struct pollfd *, fds,
+ nfds_t, nfds,
+ const struct timespec *, timeout,
+ const __sigset_t *, sigmask,
+ size_t, sigsetsize)
int
-ppoll (struct pollfd *fds, nfds_t nfds, const struct timespec *timeout,
+ppoll(struct pollfd *fds, nfds_t nfds, const struct timespec *timeout,
const __sigset_t *sigmask)
{
- /* The Linux kernel can in some situations update the timeout value.
- We do not want that so use a local variable. */
- struct timespec tval;
- if (timeout != NULL)
- {
- tval = *timeout;
- timeout = &tval;
- }
-
- return __libc_ppoll(fds, nfds, timeout, sigmask);
+ /* The Linux kernel can in some situations update the timeout value.
+ We do not want that so use a local variable. */
+ struct timespec tval;
+ if (timeout != NULL) {
+ tval = *timeout;
+ timeout = &tval;
+ }
+
+ return __libc_ppoll(fds, nfds, timeout, sigmask, _NSIG / 8);
}
libc_hidden_def(ppoll)