MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / tcp_accept

Function tcp_accept

components/net/lwip/lwip-2.1.2/src/core/tcp.c:2075–2083  ·  view source on GitHub ↗

* @ingroup tcp_raw * Used for specifying the function that should be called when a * LISTENing connection has been connected to another host. * * @param pcb tcp_pcb to set the accept callback * @param accept callback function to call for this pcb when LISTENing * connection has been connected to another host */

Source from the content-addressed store, hash-verified

2073 * connection has been connected to another host
2074 */
2075void
2076tcp_accept(struct tcp_pcb *pcb, tcp_accept_fn accept)
2077{
2078 LWIP_ASSERT_CORE_LOCKED();
2079 if ((pcb != NULL) && (pcb->state == LISTEN)) {
2080 struct tcp_pcb_listen *lpcb = (struct tcp_pcb_listen *)pcb;
2081 lpcb->accept = accept;
2082 }
2083}
2084#endif /* LWIP_CALLBACK_API */
2085
2086

Callers 5

altcp_tcp_listenFunction · 0.70
api_msg.cFile · 0.50
lwip_netconn_do_listenFunction · 0.50
httpd_initFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected