From 2b9933eb1e7f363a5c41c61cd92c66cc3c9b3e63 Mon Sep 17 00:00:00 2001 From: goldsimon Date: Tue, 27 Mar 2012 20:18:23 +0200 Subject: [PATCH] fixed bug #35945: SYN packet should provide the recv MSS not the send MSS --- CHANGELOG | 4 ++++ src/core/tcp_out.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG b/CHANGELOG index 83cd3b02..0579a6be 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -66,6 +66,10 @@ HISTORY ++ Bugfixes: + 2012-03-27: Simon Goldschmidt (patch by Mason) + * tcp_out.c: fixed bug #35945: SYN packet should provide the recv MSS not the + send MSS + 2012-03-22: Simon Goldschmidt * ip4.c: fixed bug #35927: missing refragmentaion in ip_forward diff --git a/src/core/tcp_out.c b/src/core/tcp_out.c index 50e1b6bf..ff0648ac 100644 --- a/src/core/tcp_out.c +++ b/src/core/tcp_out.c @@ -1066,7 +1066,7 @@ tcp_output_segment(struct tcp_seg *seg, struct tcp_pcb *pcb) packets, so ignore it here */ opts = (u32_t *)(void *)(seg->tcphdr + 1); if (seg->flags & TF_SEG_OPTS_MSS) { - *opts = TCP_BUILD_MSS_OPTION(pcb->mss); + *opts = TCP_BUILD_MSS_OPTION(tcp_eff_send_mss(TCP_MSS, &pcb->remote_ip)); opts += 1; } #if LWIP_TCP_TIMESTAMPS