diff options
author | Jannis Hoffmann <jannis@fehcom.de> | 2024-07-09 13:02:45 +0200 |
---|---|---|
committer | Jannis Hoffmann <jannis@fehcom.de> | 2024-07-09 13:02:45 +0200 |
commit | 96cf8dffe4f7b0b910f790066ae622dc429eb522 (patch) | |
tree | cc1343a0ac92bb4836cae2dd63a97fa045765e7f /include/iopause.h |
initial commit of version 23fehQlibs-23
Diffstat (limited to 'include/iopause.h')
-rw-r--r-- | include/iopause.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/include/iopause.h b/include/iopause.h new file mode 100644 index 0000000..e3cfa01 --- /dev/null +++ b/include/iopause.h @@ -0,0 +1,28 @@ +#ifndef IOPAUSE_H +#define IOPAUSE_H + +#define IOPAUSE_POLL + +#include <sys/types.h> +#ifdef HAS_POLL_H +#include <poll.h> + +typedef struct pollfd iopause_fd; +#define IOPAUSE_READ POLLIN +#define IOPAUSE_WRITE POLLOUT +#else +typedef struct { + int fd; + short events; + short revents; +} iopause_fd; +#define IOPAUSE_READ 1 +#define IOPAUSE_WRITE 4 +#endif + +#include "taia.h" + +extern int iopause(iopause_fd *,unsigned int,struct taia *,struct taia *); +extern unsigned long pollmax; + +#endif |