Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F170773366
D12430.id33427.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D12430.id33427.diff
View Options
Index: sys/netinet/tcp_syncache.c
===================================================================
--- sys/netinet/tcp_syncache.c
+++ sys/netinet/tcp_syncache.c
@@ -1634,9 +1634,7 @@
tlen = hlen + sizeof(struct tcphdr);
/* Determine MSS we advertize to other end of connection. */
- mssopt = tcp_mssopt(&sc->sc_inc);
- if (sc->sc_peer_mss)
- mssopt = max( min(sc->sc_peer_mss, mssopt), V_tcp_minmss);
+ mssopt = max(tcp_mssopt(&sc->sc_inc), V_tcp_minmss);
/* XXX: Assume that the entire packet will fit in a header mbuf. */
KASSERT(max_linkhdr + tlen + TCP_MAXOLEN <= MHLEN,
@@ -1985,7 +1983,7 @@
static tcp_seq
syncookie_generate(struct syncache_head *sch, struct syncache *sc)
{
- u_int i, mss, secbit, wscale;
+ u_int i, secbit, wscale;
uint32_t iss, hash;
uint8_t *secbits;
union syncookie cookie;
@@ -1995,8 +1993,8 @@
cookie.cookie = 0;
/* Map our computed MSS into the 3-bit index. */
- mss = min(tcp_mssopt(&sc->sc_inc), max(sc->sc_peer_mss, V_tcp_minmss));
- for (i = nitems(tcp_sc_msstab) - 1; tcp_sc_msstab[i] > mss && i > 0;
+ for (i = nitems(tcp_sc_msstab) - 1;
+ tcp_sc_msstab[i] > sc->sc_peer_mss && i > 0;
i--)
;
cookie.flags.mss_idx = i;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Sep 7, 1:35 PM (6 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
38464534
Default Alt Text
D12430.id33427.diff (1 KB)
Attached To
Mode
D12430: tcp: Don't "negotiate" MSS.
Attached
Detach File
Event Timeline
Log In to Comment