X-Git-Url: http://git.meshlink.io/?p=utcp;a=blobdiff_plain;f=utcp.c;h=db775a9e8a5b37cc3e15c2ff06bf8cc4236c4260;hp=2ef56ea76a451558d19d6963679f1d9c5a7e8b6c;hb=2ae2f9bbb7502589f279c329815d55ec526baffd;hpb=5e2471e7e38b68745668aa9c3b1d55297895bba2 diff --git a/utcp.c b/utcp.c index 2ef56ea..db775a9 100644 --- a/utcp.c +++ b/utcp.c @@ -587,12 +587,13 @@ ssize_t utcp_recv(struct utcp *utcp, const void *data, size_t len) { #endif if(!acceptable) { - debug("Packet not acceptable, %u <= %u + %zu < %u\n", c->rcv.nxt, hdr.seq, len, c->rcv.nxt + c->rcv.wnd); + debug("Packet not acceptable, %u <= %u + %zu < %u\n", c->rcv.nxt, hdr.seq, len, c->rcv.nxt + c->rcv.wnd); // Ignore unacceptable RST packets. if(hdr.ctl & RST) return 0; // Otherwise, send an ACK back in the hope things improve. - goto ack; + ack(c, true); + return 0; } c->snd.wnd = hdr.wnd; // TODO: move below