Add etcp_socket_add uasync integration for packet reception
This commit is contained in:
1 parent
e666c6ac1a
commit
d126d92d3f
2 files changed
+5
No files matched your search
@@ -263,6 +263,10 @@ struct ETCP_SOCKET* etcp_socket_add(struct UTUN_INSTANCE* instance, struct socka
|
||||
|
||||
// Add to instance's socket list
|
||||
e_sock->next = instance->etcp_sockets;
|
||||
// Register socket with uasync for receiving packets
|
||||
e_sock->socket_id = uasync_add_socket(instance->ua, e_sock->fd,
|
||||
etcp_connections_read_callback,
|
||||
NULL, NULL, e_sock);
|
||||
instance->etcp_sockets = e_sock;
|
||||
|
||||
return e_sock;
|
||||
|
||||
@@ -38,6 +38,7 @@ struct ETCP_SOCKET {
|
||||
int errorcode;
|
||||
size_t pkt_format_errors;
|
||||
|
||||
void* socket_id; // Socket ID from uasync_add_socket
|
||||
};
|
||||
|
||||
// ETCP Link - одно динамическое соединение (один путь)
|
||||
|
||||
Reference in new issue
Block a user