summaryrefslogtreecommitdiffstats
path: root/osdep/polldev.h
diff options
context:
space:
mode:
Diffstat (limited to 'osdep/polldev.h')
-rw-r--r--osdep/polldev.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/osdep/polldev.h b/osdep/polldev.h
new file mode 100644
index 0000000000..50b6db29bc
--- /dev/null
+++ b/osdep/polldev.h
@@ -0,0 +1,7 @@
+#pragma once
+
+#include <poll.h>
+
+// Behaves like poll(3) but works for device files on macOS.
+// Only supports POLLIN, POLLOUT, and POLLERR.
+int polldev(struct pollfd fds[], nfds_t nfds, int timeout);