Moonlight-XboxOG latest
Moonlight Xbox OG is a port of the Moonlight Game Streaming client to the original Xbox console.
poll_compat.cpp File Reference

Implements poll compatibility shims for nxdk. More...

#include <cerrno>
#include <cstddef>
#include <poll.h>
#include <sys/socket.h>
#include <sys/time.h>
Include dependency graph for poll_compat.cpp:

Functions

int poll (struct pollfd *fds, nfds_t nfds, int timeout)
 Emulate poll by translating the requested events into select sets.
 

Detailed Description

Implements poll compatibility shims for nxdk.

Function Documentation

◆ poll()

int poll ( struct pollfd * fds,
nfds_t nfds,
int timeout )

Emulate poll by translating the requested events into select sets.

Parameters
fdsFile descriptor array to test.
nfdsNumber of entries in fds.
timeoutTimeout in milliseconds, or a negative value to wait indefinitely.
Returns
Number of ready descriptors, zero on timeout, or -1 on error.