This commit is contained in:
2025-11-06 01:00:39 +01:00
parent d192209c58
commit e7455cc4ed
3 changed files with 101 additions and 66 deletions
+2
View File
@@ -343,6 +343,8 @@ int tcp_connect(TCP *tcp, Address addr, int tag, ByteQueue **output)
void tcp_close(TCP *tcp, int conn_idx)
{
tcp->conns[conn_idx].closing = true;
// TODO: if no event will be triggered, the connection will not be closed
// if the output buffer is empty, the connection should be closed here.
}
void tcp_set_tag(TCP *tcp, int conn_idx, int tag)