diff --git a/net/local/local.h b/net/local/local.h index df0777d0bb..ef7421722b 100644 --- a/net/local/local.h +++ b/net/local/local.h @@ -118,20 +118,7 @@ struct local_conn_s { /* Common prologue of all connection structures. */ - /* lc_node supports a doubly linked list: Listening SOCK_STREAM servers - * will be linked into a list of listeners; SOCK_STREAM clients will be - * linked to the lc_conn lists. - */ - - dq_entry_t lc_node; /* Supports a doubly linked list */ - - /* This is a list of Local connection callbacks. Each callback represents - * a thread that is stalled, waiting for a device-specific event. - * REVISIT: Here for commonality with other connection structures; not - * used in the current implementation. - */ - - FAR struct devif_callback_s *lc_list; + struct socket_conn_s lc_conn; /* Local-socket specific content follows */ diff --git a/net/local/local_conn.c b/net/local/local_conn.c index a32c87492e..72fb1d13de 100644 --- a/net/local/local_conn.c +++ b/net/local/local_conn.c @@ -79,7 +79,7 @@ FAR struct local_conn_s *local_nextconn(FAR struct local_conn_s *conn) return (FAR struct local_conn_s *)g_local_connections.head; } - return (FAR struct local_conn_s *)conn->lc_node.flink; + return (FAR struct local_conn_s *)conn->lc_conn.node.flink; } /**************************************************************************** @@ -143,7 +143,7 @@ FAR struct local_conn_s *local_alloc(void) /* Add the connection structure to the list of listeners */ net_lock(); - dq_addlast(&conn->lc_node, &g_local_connections); + dq_addlast(&conn->lc_conn.node, &g_local_connections); net_unlock(); } @@ -170,7 +170,7 @@ void local_free(FAR struct local_conn_s *conn) /* Remove the server from the list of listeners. */ net_lock(); - dq_rem(&conn->lc_node, &g_local_connections); + dq_rem(&conn->lc_conn.node, &g_local_connections); #ifdef CONFIG_NET_LOCAL_SCM if (local_peerconn(conn) && conn->lc_peer) diff --git a/net/local/local_listen.c b/net/local/local_listen.c index 77e10fed72..409bf1c336 100644 --- a/net/local/local_listen.c +++ b/net/local/local_listen.c @@ -107,7 +107,7 @@ int local_listen(FAR struct socket *psock, int backlog) { /* The connection should not reside in any other list */ - DEBUGASSERT(server->lc_node.flink == NULL); + DEBUGASSERT(server->lc_conn.node.flink == NULL); /* And change the server state to listing */