Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F143130965
D8272.id21460.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
715 B
Referenced Files
None
Subscribers
None
D8272.id21460.diff
View Options
Index: sys/netinet/tcp_input.c
===================================================================
--- sys/netinet/tcp_input.c
+++ sys/netinet/tcp_input.c
@@ -3758,7 +3758,15 @@
(void)sbreserve_locked(&so->so_snd, bufsize, so, NULL);
}
SOCKBUF_UNLOCK(&so->so_snd);
- tp->t_maxseg = mss;
+ /*
+ * Sanity check: make sure that maxseg will be large
+ * enough to allow some data on segments even if the
+ * all the option space is used (40bytes). Otherwise
+ * funny things may happen in tcp_output.
+ *
+ * XXXGL: shouldn't we reserve space for IP/IPv6 options?
+ */
+ tp->t_maxseg = max(mss, 64);
SOCKBUF_LOCK(&so->so_rcv);
if ((so->so_rcv.sb_hiwat == V_tcp_recvspace) && metrics.rmx_recvpipe)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Jan 27, 9:09 AM (19 h, 57 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28053445
Default Alt Text
D8272.id21460.diff (715 B)
Attached To
Mode
D8272: Make sure tcp_mss() has the same check as tcp_mss_update() to have t_maxseg set to at least 64.
Attached
Detach File
Event Timeline
Log In to Comment