mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-12-26 03:16:18 +00:00
tcp: Prevents a 0 sized (invalid) backlog
commit44e1a2d8e2
accidently includes below changes in tcp_listen_with_backlog - tcp_backlog_set(lpcb, backlog); + lpcb->backlog = backlog; Thus pass 0 to the backlog parameter of netconn_listen_with_backlog() fails. Fixes:44e1a2d8e2
("define tcp_backlog_set() as dummy-define when backlog feature is disable") Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: goldsimon <goldsimon@gmx.de>
This commit is contained in:
parent
298ec340e5
commit
bf5866b27d
@ -688,7 +688,7 @@ tcp_listen_with_backlog(struct tcp_pcb *pcb, u8_t backlog)
|
||||
#endif /* LWIP_CALLBACK_API */
|
||||
#if TCP_LISTEN_BACKLOG
|
||||
lpcb->accepts_pending = 0;
|
||||
lpcb->backlog = backlog;
|
||||
tcp_backlog_set(lpcb, backlog);
|
||||
#endif /* TCP_LISTEN_BACKLOG */
|
||||
TCP_REG(&tcp_listen_pcbs.pcbs, (struct tcp_pcb *)lpcb);
|
||||
return (struct tcp_pcb *)lpcb;
|
||||
|
Loading…
Reference in New Issue
Block a user