diff options
author | Michael Tuexen <tuexen@fh-muenster.de> | 2020-05-10 12:08:05 +0200 |
---|---|---|
committer | Michael Tuexen <tuexen@fh-muenster.de> | 2020-05-10 12:08:05 +0200 |
commit | bfa530e2a52ac3c7dd1a53bf78111a9476ebfd99 (patch) | |
tree | 44da42d7dc8f36ae3ce9f054ecbed0c2b2a7ec2b | |
parent | 0cb61bc48f7fda14aea12d34dcd3ae3ac136e076 (diff) | |
download | usrsctp-bfa530e2a52ac3c7dd1a53bf78111a9476ebfd99.tar.gz |
Only drop DATA chunk with lower priority as specified in RFC 7496.
-rwxr-xr-x | usrsctplib/netinet/sctp_output.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usrsctplib/netinet/sctp_output.c b/usrsctplib/netinet/sctp_output.c index d4595fe7..f9ec0068 100755 --- a/usrsctplib/netinet/sctp_output.c +++ b/usrsctplib/netinet/sctp_output.c @@ -34,7 +34,7 @@ #ifdef __FreeBSD__ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: head/sys/netinet/sctp_output.c 360671 2020-05-05 19:54:30Z tuexen $"); +__FBSDID("$FreeBSD: head/sys/netinet/sctp_output.c 360869 2020-05-10 10:03:10Z tuexen $"); #endif #include <netinet/sctp_os.h> @@ -6690,11 +6690,11 @@ sctp_prune_prsctp(struct sctp_tcb *stcb, * This one is PR-SCTP AND buffer space * limited type */ - if (chk->rec.data.timetodrop.tv_sec >= (long)srcv->sinfo_timetolive) { + if (chk->rec.data.timetodrop.tv_sec > (long)srcv->sinfo_timetolive) { /* * Lower numbers equates to higher * priority so if the one we are - * looking at has a larger or equal + * looking at has a larger * priority we want to drop the data * and NOT retransmit it. */ @@ -6725,7 +6725,7 @@ sctp_prune_prsctp(struct sctp_tcb *stcb, TAILQ_FOREACH_SAFE(chk, &asoc->send_queue, sctp_next, nchk) { /* Here we must move to the sent queue and mark */ if (PR_SCTP_BUF_ENABLED(chk->flags)) { - if (chk->rec.data.timetodrop.tv_sec >= (long)srcv->sinfo_timetolive) { + if (chk->rec.data.timetodrop.tv_sec > (long)srcv->sinfo_timetolive) { if (chk->data) { /* * We release the book_size @@ -13640,8 +13640,8 @@ sctp_lower_sosend(struct socket *so, sndlen = SCTP_HEADER_LEN(i_pak); #endif } - SCTPDBG(SCTP_DEBUG_OUTPUT1, "Send called addr:%p send length %zu\n", - (void *)addr, + SCTPDBG(SCTP_DEBUG_OUTPUT1, "Send called addr:%p send length %zd\n", + (void *)addr, sndlen); #ifdef __Panda__ if (i_control) { |