On Fri, 2007-06-08 at 10:35 +0200, Per-Henrik Lundblom wrote: > Hi, > > When heavily opening and closing the tcp receive window on one side of a > TCP connection, I ran into the problem with the TCP sstresh value being > set to 0 resulting in a stop of transmission. My interpretion of the > TCP standards (carefully studying of TCP/IP Illustrated) is that sstresh > never should be assigned a value less than one MSS. Adding zero value > check to the code solved all the transmissions stops. > > My proposed patch against 1.2.0 is: > > --- lwip-1.2.0/src/core/tcp_in.c 2006-08-18 12:18:42.000000000 > +0200 > +++ lwip-1.2.0_patched/src/core/tcp_in.c 2007-06-08 > 10:24:42.451875000 +0200 > @@ -678,6 +678,9 @@ > pcb->ssthresh = pcb->snd_wnd / 2; > else > pcb->ssthresh = pcb->cwnd / 2; > + > + if (pcb->sstresh == 0) > + pcb->sstresh = pcb->mss;
If it shouldn't be less than 1 mss wouldn't this be better? if (pcb->ssthresh < pcb->mss) pcb->ssthresh = pcb->mss Either way, could you file a bug on savannah so that this gets tracked and fixed? Thanks Kieran _______________________________________________ lwip-users mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/lwip-users
