Go to the documentation of this file.
28 #include <sys/socket.h>
29 #include <sys/ioctl.h>
47 return errno == EAGAIN
48 || errno == EINPROGRESS
50 || errno == EWOULDBLOCK
79 while (
n == -1 && errno == EINTR);
80 ASSERT(
n >= 0 || errno != EINVAL);
91 while (
n == -1 && errno == EINTR);
92 ASSERT(
n >= 0 || errno != EINVAL);
105 while (
n == -1 && errno == EINTR);
119 while (
n == -1 && errno == EINTR);
120 ASSERT(
n >= 0 || errno != EINVAL);
130 }
while (
n < 0 && errno == EINTR);
151 }
while (
r < 0 && errno == EINTR);
156 }
while (
r < 0 && errno == EINTR);
164 struct sockaddr_in
addr;
186 }
while (
r == -1 && errno == EINTR);
return memset(p, 0, total)
static void connection_cb(uv_stream_t *handle, int status)
static uv_os_fd_t server_fd
UV_EXTERN int uv_poll_init_socket(uv_loop_t *loop, uv_poll_t *handle, uv_os_sock_t socket)
UV_EXTERN int uv_listen(uv_stream_t *stream, int backlog, uv_connection_cb cb)
static void poll_cb(uv_poll_t *handle, int status, int events)
UV_EXTERN int uv_run(uv_loop_t *, uv_run_mode mode)
UV_EXTERN int uv_poll_start(uv_poll_t *handle, int events, uv_poll_cb cb)
UV_EXTERN int uv_tcp_bind(uv_tcp_t *handle, const struct sockaddr *addr, unsigned int flags)
UV_EXTERN void uv_close(uv_handle_t *handle, uv_close_cb close_cb)
UV_EXTERN int uv_ip4_addr(const char *ip, int port, struct sockaddr_in *addr)
UV_EXTERN uv_loop_t * uv_default_loop(void)
static uv_os_fd_t client_fd
UV_EXTERN int uv_tcp_init(uv_loop_t *, uv_tcp_t *handle)
UV_EXTERN int uv_accept(uv_stream_t *server, uv_stream_t *client)
static uv_tcp_t client_handle
UV_EXTERN void uv_sleep(unsigned int msec)
static uv_tcp_t server_handle
static void idle_cb(uv_idle_t *idle)
static uv_tcp_t peer_handle
UV_EXTERN int uv_idle_init(uv_loop_t *, uv_idle_t *idle)
static const int kMaxTicks
#define MAKE_VALGRIND_HAPPY()
UV_EXTERN int uv_fileno(const uv_handle_t *handle, uv_os_fd_t *fd)
UV_EXTERN int uv_idle_start(uv_idle_t *idle, uv_idle_cb cb)
UV_EXTERN int uv_poll_stop(uv_poll_t *handle)
UV_EXTERN int uv_tcp_nodelay(uv_tcp_t *handle, int enable)
static int got_eagain(void)
static uv_poll_t poll_req[2]
grpc
Author(s):
autogenerated on Fri May 16 2025 03:00:26