/* * for the MontaukOS git port. * * git polls only descriptors it created itself with pipe() -- the stdout and * stderr of a spawned sub-process (run-command.c's pump loop, sideband * demultiplexing). MontaukOS has neither pipe() nor fork(), so those code * paths are unreachable at runtime; this header exists so they compile, and * the implementation reports every descriptor ready so that a caller which * somehow gets here makes progress into the read() that reports the real * error, instead of spinning in the poll loop forever. * * git's own compat/poll (NO_POLL=1) is not used: it is written against * select() and , neither of which exists here. * * Implementation in montauk-compat.c. */ #ifndef _MONTAUK_GIT_POLL_H_ #define _MONTAUK_GIT_POLL_H_ typedef unsigned long nfds_t; struct pollfd { int fd; short events; short revents; }; #define POLLIN 0x001 #define POLLPRI 0x002 #define POLLOUT 0x004 #define POLLERR 0x008 #define POLLHUP 0x010 #define POLLNVAL 0x020 int poll(struct pollfd *fds, nfds_t nfds, int timeout); #endif /* _MONTAUK_GIT_POLL_H_ */