blob: 36ef7fee5892b401cd932d2b3248b0bab16d34a4 [file] [log] [blame]
Rich Felker0b44a032011-02-12 00:22:29 -05001#ifndef _POLL_H
2#define _POLL_H
3
4#ifdef __cplusplus
5extern "C" {
6#endif
7
8#define POLLIN 0x001
9#define POLLPRI 0x002
10#define POLLOUT 0x004
11#define POLLERR 0x008
12#define POLLHUP 0x010
13#define POLLNVAL 0x020
14#define POLLRDNORM 0x040
15#define POLLRDBAND 0x080
16#define POLLWRNORM 0x100
17#define POLLWRBAND 0x200
18#define POLLMSG 0x400
19
Rich Felker3f62f762012-09-01 00:20:24 -040020typedef unsigned long nfds_t;
Rich Felker0b44a032011-02-12 00:22:29 -050021
22struct pollfd
23{
24 int fd;
25 short events;
26 short revents;
27};
28
29int poll (struct pollfd *, nfds_t, int);
30
31#ifdef __cplusplus
32}
33#endif
34
35#endif