mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-10-02 12:52:10 +00:00
Ensure ssthresh >= 2*MSS
This commit is contained in:
parent
21e3cde95c
commit
95445fc328
@ -56,6 +56,8 @@ HISTORY
|
|||||||
|
|
||||||
|
|
||||||
++ Bugfixes:
|
++ Bugfixes:
|
||||||
|
2010-01-28: Kieran Mansley
|
||||||
|
* tcp.c: Ensure ssthresh >= 2*MSS
|
||||||
|
|
||||||
2010-01-27: Simon Goldschmidt
|
2010-01-27: Simon Goldschmidt
|
||||||
* tcp.h, tcp.c, tcp_in.c: Fixed bug #27871: Calling tcp_abort() in recv
|
* tcp.h, tcp.c, tcp_in.c: Fixed bug #27871: Calling tcp_abort() in recv
|
||||||
|
@ -650,8 +650,8 @@ tcp_slowtmr(void)
|
|||||||
/* Reduce congestion window and ssthresh. */
|
/* Reduce congestion window and ssthresh. */
|
||||||
eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd);
|
eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd);
|
||||||
pcb->ssthresh = eff_wnd >> 1;
|
pcb->ssthresh = eff_wnd >> 1;
|
||||||
if (pcb->ssthresh < pcb->mss) {
|
if (pcb->ssthresh < (pcb->mss << 1)) {
|
||||||
pcb->ssthresh = pcb->mss * 2;
|
pcb->ssthresh = (pcb->mss << 1);
|
||||||
}
|
}
|
||||||
pcb->cwnd = pcb->mss;
|
pcb->cwnd = pcb->mss;
|
||||||
LWIP_DEBUGF(TCP_CWND_DEBUG, ("tcp_slowtmr: cwnd %"U16_F
|
LWIP_DEBUGF(TCP_CWND_DEBUG, ("tcp_slowtmr: cwnd %"U16_F
|
||||||
|
Loading…
Reference in New Issue
Block a user