static void uv__udp_io(uv_loop_t* loop, uv__io_t* w, unsigned int revents) { if (revents & UV__POLLIN) uv__udp_recvmsg(loop, w, revents); if (revents & UV__POLLOUT) uv__udp_sendmsg(loop, w, revents); }
static void uv__udp_io(uv_loop_t* loop, uv__io_t* w, unsigned int revents) { uv_udp_t* handle; handle = container_of(w, uv_udp_t, io_watcher); assert(handle->type == UV_UDP); if (revents & UV__POLLIN) uv__udp_recvmsg(handle); if (revents & UV__POLLOUT) { uv__udp_sendmsg(handle); uv__udp_run_completed(handle); } }
static void uv__udp_io(EV_P_ ev_io* w, int events) { uv_udp_t* handle; handle = w->data; assert(handle != NULL); assert(handle->type == UV_UDP); assert(handle->fd >= 0); assert(!(events & ~(EV_READ|EV_WRITE))); if (events & EV_READ) uv__udp_recvmsg(handle); if (events & EV_WRITE) uv__udp_sendmsg(handle); }