Libuv:TCP
lastmod 2026-11-10created 2016-11-053 edits
The TCP handle (uv_tcp_t) in libuv is used to implement asynchronous TCP servers and clients. It accepts connections with uv_tcp_bind and uv_listen, handles stream I/O with uv_read_start and uv_write, and gets the local and remote addresses with uv_tcp_getsockname and uv_tcp_getpeername. Every operation is reported through callbacks on the event loop.
See also
Favorite site
- libuv: starting a TCP server listener and getting the client's IP and port (uv_tcp_getsockname & uv_tcp_getpeername)