* @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 */
| 2073 | * connection has been connected to another host |
| 2074 | */ |
| 2075 | void |
| 2076 | tcp_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 |
no outgoing calls
no test coverage detected