mirror of
https://github.com/ep00ch/lwip-contrib-mac.git
synced 2025-02-22 08:29:06 +00:00
Fixed my last checkin that fixed bug #27117: "httpserver_raw sample does not call tcp_accepted()" accidentally called tcp_accepted() on the connection-pcb, not the listen-pcb
This commit is contained in:
parent
47521ce2bc
commit
4a5c399e7d
@ -208,12 +208,13 @@ static err_t
|
||||
http_accept(void *arg, struct tcp_pcb *pcb, err_t err)
|
||||
{
|
||||
struct http_state *hs;
|
||||
struct tcp_pcb_listen *lpcb = (struct tcp_pcb_listen*)arg;
|
||||
|
||||
LWIP_UNUSED_ARG(arg);
|
||||
LWIP_UNUSED_ARG(err);
|
||||
|
||||
/* Decrease the listen backlog counter */
|
||||
tcp_accepted(pcb);
|
||||
tcp_accepted(lpcb);
|
||||
|
||||
tcp_setprio(pcb, TCP_PRIO_MIN);
|
||||
|
||||
@ -254,6 +255,7 @@ httpd_init(void)
|
||||
pcb = tcp_new();
|
||||
tcp_bind(pcb, IP_ADDR_ANY, 80);
|
||||
pcb = tcp_listen(pcb);
|
||||
tcp_arg(pcb, pcb);
|
||||
tcp_accept(pcb, http_accept);
|
||||
}
|
||||
/*-----------------------------------------------------------------------------------*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user