Commit 829c590c authored by Jon Grimm's avatar Jon Grimm

sctp: Fix bug where we were erroneously throwing away packets > frag_point. (jgrimm)

parent 22bf2be7
...@@ -1948,17 +1948,16 @@ sctp_disposition_t sctp_sf_eat_data_6_2(const sctp_endpoint_t *ep, ...@@ -1948,17 +1948,16 @@ sctp_disposition_t sctp_sf_eat_data_6_2(const sctp_endpoint_t *ep,
/* This is a new TSN. */ /* This is a new TSN. */
/* If we don't have any room in our receive window, discard. /* Discard if there is no room in the receive window.
* Actually, allow a little bit of overflow (up to a MTU of * Actually, allow a little bit of overflow (up to a MTU).
* of overflow).
*/ */
datalen = ntohs(chunk->chunk_hdr->length); datalen = ntohs(chunk->chunk_hdr->length);
datalen -= sizeof(sctp_data_chunk_t); datalen -= sizeof(sctp_data_chunk_t);
if (!asoc->rwnd || (datalen > asoc->frag_point)) { if (asoc->rwnd_over || (datalen > asoc->rwnd + asoc->frag_point)) {
SCTP_DEBUG_PRINTK("Discarding tsn: %u datalen: %Zd, " SCTP_DEBUG_PRINTK("Discarding tsn: %u datalen: %Zd, "
"rwnd: %d\n", tsn, datalen, asoc->rwnd); "rwnd: %d\n", tsn, datalen, asoc->rwnd);
goto discard_noforce; goto discard_force;
} }
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment