summaryrefslogtreecommitdiff
path: root/sys/netinet/sctp_cc_functions.c
diff options
context:
space:
mode:
authorMichael Tuexen <tuexen@FreeBSD.org>2010-09-15 20:53:20 +0000
committerMichael Tuexen <tuexen@FreeBSD.org>2010-09-15 20:53:20 +0000
commit107cad7449dc0b00ba7cfcb458f8958ccd1c8d38 (patch)
treeb357eec06179fa709f302f9591e1fd1cd3744605 /sys/netinet/sctp_cc_functions.c
parent15537f41b444170cb3dec4e0c09cf101914c3122 (diff)
downloadsrc-test2-107cad7449dc0b00ba7cfcb458f8958ccd1c8d38.tar.gz
src-test2-107cad7449dc0b00ba7cfcb458f8958ccd1c8d38.zip
Notes
Diffstat (limited to 'sys/netinet/sctp_cc_functions.c')
-rw-r--r--sys/netinet/sctp_cc_functions.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/netinet/sctp_cc_functions.c b/sys/netinet/sctp_cc_functions.c
index 1cba25a2de34..8d2afc619e49 100644
--- a/sys/netinet/sctp_cc_functions.c
+++ b/sys/netinet/sctp_cc_functions.c
@@ -171,7 +171,7 @@ sctp_cwnd_update_after_sack(struct sctp_tcb *stcb,
* So, first of all do we need to have a Early FR
* timer running?
*/
- if (((TAILQ_FIRST(&asoc->sent_queue)) &&
+ if ((!TAILQ_EMPTY(&asoc->sent_queue) &&
(net->ref_count > 1) &&
(net->flight_size < net->cwnd)) ||
(reneged_all)) {
@@ -656,7 +656,6 @@ sctp_hs_cwnd_decrease(struct sctp_tcb *stcb, struct sctp_nets *net)
int old_cwnd = net->cwnd;
cur_val = net->cwnd >> 10;
- indx = net->last_hs_used;
if (cur_val < sctp_cwnd_adjust[0].cwnd) {
/* normal mode */
net->ssthresh = net->cwnd / 2;
@@ -793,7 +792,7 @@ sctp_hs_cwnd_update_after_sack(struct sctp_tcb *stcb,
* So, first of all do we need to have a Early FR
* timer running?
*/
- if (((TAILQ_FIRST(&asoc->sent_queue)) &&
+ if ((!TAILQ_EMPTY(&asoc->sent_queue) &&
(net->ref_count > 1) &&
(net->flight_size < net->cwnd)) ||
(reneged_all)) {
@@ -1279,7 +1278,7 @@ sctp_htcp_cwnd_update_after_sack(struct sctp_tcb *stcb,
* So, first of all do we need to have a Early FR
* timer running?
*/
- if (((TAILQ_FIRST(&asoc->sent_queue)) &&
+ if ((!TAILQ_EMPTY(&asoc->sent_queue) &&
(net->ref_count > 1) &&
(net->flight_size < net->cwnd)) ||
(reneged_all)) {