nbd_poll23
Poll the handle once, with fd
Usage
#include <libnbd.h>int nbd_poll2 (struct nbd_handle *h, int fd, int timeout);
Overview
This is the same as nbd_poll(3), but an additional file descriptor parameter is passed. The additional fd is also polled (using "POLLIN"). One use for this is to wait for an eventfd(2).
Return value
This call returns an integer ≥ 0.
Errors
On error -1 is returned.
Refer to "ERROR HANDLING" in libnbd(3) for how to get further details of the error.
The following parameters must not be NULL: "h". For more information see "Non-NULL parameters" in libnbd(3).
Version
This function first appeared in libnbd 1.16.
If you need to test if this function is available at compile time check if the following macro is defined:
#define LIBNBD_HAVE_NBD_POLL2 1
Releases
2 releases since Debian 13 (Trixie); the text changed 1 time.