| Index: sysdeps/nacl/irt_syscalls.h
|
| diff --git a/sysdeps/nacl/irt_syscalls.h b/sysdeps/nacl/irt_syscalls.h
|
| index ac4fd6439bab39498dfb42d61db63abd9f40d912..b68c413f8f147967bc9ce5cbe8f0f7daeb7b2747 100644
|
| --- a/sysdeps/nacl/irt_syscalls.h
|
| +++ b/sysdeps/nacl/irt_syscalls.h
|
| @@ -2,6 +2,8 @@
|
| #define _IRT_SYSCALLS_H
|
|
|
| #include <sys/types.h>
|
| +#include <sys/epoll.h>
|
| +#include <poll.h>
|
| #include <stddef.h>
|
| #include <fcntl.h>
|
| #include <time.h>
|
| @@ -12,6 +14,8 @@ struct dirent;
|
| struct nacl_abi_stat;
|
| struct timeval;
|
| struct timespec;
|
| +struct sockaddr;
|
| +#define socklen_t unsigned int
|
|
|
| extern size_t (*__nacl_irt_query)(const char *interface_ident,
|
| void *table, size_t tablesize);
|
| @@ -29,6 +33,38 @@ extern int (*__nacl_irt_rmdir) (const char* pathname);
|
| extern int (*__nacl_irt_chdir) (const char* pathname);
|
| extern int (*__nacl_irt_getcwd) (char* buf, size_t size, int* ret);
|
|
|
| +extern int (*__nacl_irt_epoll_create) (int flags); // size
|
| +extern int (*__nacl_irt_epoll_create1 )(int flags);
|
| +extern int (*__nacl_irt_epoll_ctl) (int epfd, int op, int fd, struct epoll_event *event);
|
| +extern int (*__nacl_irt_epoll_pwait) (int epfd, struct epoll_event *events,
|
| + int maxevents, int timeout,
|
| + const sigset_t *sigmask, size_t sigsetsize);
|
| +extern int (*__nacl_irt_epoll_wait) (int epfd, struct epoll_event *events,
|
| + int maxevents, int timeout);
|
| +extern int (*__nacl_irt_poll) (struct pollfd *fds, nfds_t nfds,
|
| + int timeout);
|
| +extern int (*__nacl_irt_ppoll) (struct pollfd *fds, nfds_t nfds,
|
| + const struct timespec *timeout,
|
| + const sigset_t *sigmask, size_t sigsetsize);
|
| +extern int (*__nacl_irt_socket) (int domain, int type, int protocol);
|
| +extern int (*__nacl_irt_accept) (int sockfd, struct sockaddr *addr, socklen_t *addrlen);
|
| +extern int (*__nacl_irt_bind) (int sockfd, struct sockaddr *addr, socklen_t addrlen);
|
| +extern int (*__nacl_irt_listen) (int sockfd, int backlog);
|
| +extern int (*__nacl_irt_connect) (int sockfd, struct sockaddr *addr, socklen_t *addrlen);
|
| +extern int (*__nacl_irt_send) (int sockfd, const void *buf, size_t len, int flags);
|
| +extern int (*__nacl_irt_sendto) (int sockfd, const void *buf, size_t len, int flags,
|
| + const struct sockaddr *dest_addr, socklen_t addrlen);
|
| +extern int (*__nacl_irt_recv) (int sockfd, void *buf, size_t len, int flags);
|
| +extern int (*__nacl_irt_recvfrom) (int sockfd, void *buf, size_t len, int flags,
|
| + struct sockaddr *dest_addr, socklen_t addrlen);
|
| +extern int (*__nacl_irt_select) (int nfds, fd_set *readfds,
|
| + fd_set *writefds, fd_set *exceptfds,
|
| + const struct timeval *timeout);
|
| +extern int (*__nacl_irt_pselect) (int nfds, fd_set *readfds,
|
| + fd_set *writefds, fd_set *exceptfds,
|
| + const struct timeval *timeout, void* sigmask);
|
| +
|
| +
|
| extern int (*__nacl_irt_open) (const char *pathname, int oflag, mode_t cmode,
|
| int *newfd);
|
| extern int (*__nacl_irt_close) (int fd);
|
| @@ -81,6 +117,7 @@ extern int (*__nacl_irt_open_resource) (const char* file, int *fd);
|
|
|
| extern int (*__nacl_irt_clock_getres) (clockid_t clk_id, struct timespec *res);
|
| extern int (*__nacl_irt_clock_gettime) (clockid_t clk_id, struct timespec *tp);
|
| +#undef socklen_t
|
|
|
| #ifdef _LIBC
|
| void init_irt_table (void) attribute_hidden;
|
| @@ -115,7 +152,6 @@ void init_irt_table (void) attribute_hidden;
|
| #include <sys/poll.h>
|
| #include <sys/ptrace.h>
|
| #include <sys/times.h>
|
| -#include <sys/types.h>
|
| #include <sys/wait.h>
|
| #include <time.h>
|
| #include <utime.h>
|
|
|