mihaic's projects
/
dragonfly.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
859bc3f
)
tcp/ncr: Avoid using magic number
author
Sepherosa Ziehau <sephe@dragonflybsd.org>
Tue, 28 Aug 2012 07:10:58 +0000 (15:10 +0800)
committer
Sepherosa Ziehau <sephe@dragonflybsd.org>
Tue, 28 Aug 2012 07:10:58 +0000 (15:10 +0800)
sys/netinet/tcp_input.c
patch
|
blob
|
blame
|
history
diff --git
a/sys/netinet/tcp_input.c
b/sys/netinet/tcp_input.c
index
53e07f0
..
2c9bdbc
100644
(file)
--- a/
sys/netinet/tcp_input.c
+++ b/
sys/netinet/tcp_input.c
@@
-364,7
+364,7
@@
tcp_ncr_update_rxtthresh(struct tcpcb *tp)
int old_rxtthresh = tp->t_rxtthresh;
uint32_t ownd = tp->snd_max - tp->snd_una;
- tp->t_rxtthresh = max(3, ((ownd / tp->t_maxseg) >> 1));
+ tp->t_rxtthresh = max(tcprexmtthresh, ((ownd / tp->t_maxseg) >> 1));
if (tp->t_rxtthresh != old_rxtthresh) {
tcp_sack_update_lostseq(&tp->scb, tp->snd_una,
tp->t_maxseg, tp->t_rxtthresh);