M pc/main.c => pc/main.c +7 -3
@@ 242,27 242,31 @@ confinit(void)
* size the non-standard memory
*/
x = 0x12345678;
- for(i=1; i<16; i++){
+ for(i=2; i<17; i++){
/*
* write the word
*/
l = (long*)(KZERO|(i*MB));
+ l--;
*l = x;
/*
* take care of wraps
*/
- for(j = 0; j < i; j++){
+ for(j = 1; j < i; j++){
l = (long*)(KZERO|(j*MB));
- *l = 0;
+ l--;
+ *l = ~x;
}
/*
* check
*/
l = (long*)(KZERO|(i*MB));
+ l--;
if(*l != x)
break;
x += 0x3141526;
}
+ i--;
conf.base1 = 1*MB;
conf.npage1 = (i*MB - conf.base1)/BY2PG;
conf.npage = conf.npage0 + conf.npage1;
M port/tcpoutput.c => port/tcpoutput.c +7 -4
@@ 45,8 45,12 @@ tcpoutput(Ipconv *s)
* window probes to one
*/
if(tcb->snd.wnd == 0){
- if(sent != 0)
- break;
+ if(sent != 0) {
+ if (tcb->flags&FORCE)
+ tcb->snd.ptr = tcb->snd.una;
+ else
+ break;
+ }
usable = 1;
}
else {
@@ 176,11 180,10 @@ tcptimeout(void *arg)
s = (Ipconv *)arg;
tcb = &s->tcpctl;
-
switch(tcb->state){
default:
tcb->backoff++;
- if (tcb->backoff >= MAXBACKOFF) {
+ if (tcb->backoff >= MAXBACKOFF && tcb->snd.wnd > 0) {
localclose(s, Etimedout);
break;
}