Improve documentation for event flags on init and callback

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson
2017-09-20 08:59:39 +02:00
parent 649f40e5d3
commit b67c62045f
3 changed files with 11 additions and 7 deletions
+1 -1
View File
@@ -33,7 +33,7 @@
* @param cb I/O callback
* @param arg Optional callback argument
* @param fd File descriptor to watch, or -1 to register an empty watcher
* @param events Requested events to watch for, a mask of %UEV_READ, %UEV_WRITE and %UEV_PRI
* @param events Events to watch for: %UEV_READ, %UEV_WRITE, %UEV_EDGE, %UEV_ONESHOW
*
* @return POSIX OK(0) or non-zero with @param errno set on error.
*/
+5 -1
View File
@@ -61,7 +61,11 @@ typedef struct uev {
uev_ctx_t *ctx;
} uev_t;
/* Generic callback for watchers */
/*
* Generic callback for watchers, @events holds %UEV_READ and/or %UEV_WRITE
* with optional %UEV_PRI (priority data available to read) and any of the
* %UEV_HUP and/or %UEV_RDHUP, which may be used to signal hang-up events.
*/
typedef void (uev_cb_t)(uev_t *w, void *arg, int events);
/* Public interface */