summaryrefslogtreecommitdiffstats
path: root/sys/netinet/tcp_reass.c
diff options
context:
space:
mode:
authordg <dg@FreeBSD.org>1996-02-22 11:46:39 +0000
committerdg <dg@FreeBSD.org>1996-02-22 11:46:39 +0000
commit41aff73dfb837f461109e0810dd130bc2a822add (patch)
treec6010a589cb4533a47d976424032e3585b8bd405 /sys/netinet/tcp_reass.c
parentde7b925ea4f07bda58d3890ee8c64a72d11b7244 (diff)
downloadFreeBSD-src-41aff73dfb837f461109e0810dd130bc2a822add.zip
FreeBSD-src-41aff73dfb837f461109e0810dd130bc2a822add.tar.gz
Fixed bug in Path MTU Discovery that caused the system to have to re-
discover the Path MTU for each connection if the connecting host didn't offer an initial MSS. Submitted by: davidg & olah
Diffstat (limited to 'sys/netinet/tcp_reass.c')
-rw-r--r--sys/netinet/tcp_reass.c28
1 files changed, 4 insertions, 24 deletions
diff --git a/sys/netinet/tcp_reass.c b/sys/netinet/tcp_reass.c
index 4fbe209..1c08251 100644
--- a/sys/netinet/tcp_reass.c
+++ b/sys/netinet/tcp_reass.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)tcp_input.c 8.12 (Berkeley) 5/24/95
- * $Id: tcp_input.c,v 1.34 1995/12/14 09:53:47 phk Exp $
+ * $Id: tcp_input.c,v 1.35 1996/01/31 08:22:24 olah Exp $
*/
#ifndef TUBA_INCLUDE
@@ -331,23 +331,6 @@ tcp_input(m, iphlen)
}
optlen = off - sizeof (struct tcphdr);
optp = mtod(m, u_char *) + sizeof (struct tcpiphdr);
- /*
- * Do quick retrieval of timestamp options ("options
- * prediction?"). If timestamp is the only option and it's
- * formatted as recommended in RFC 1323 appendix A, we
- * quickly get the values now and not bother calling
- * tcp_dooptions(), etc.
- */
- if ((optlen == TCPOLEN_TSTAMP_APPA ||
- (optlen > TCPOLEN_TSTAMP_APPA &&
- optp[TCPOLEN_TSTAMP_APPA] == TCPOPT_EOL)) &&
- *(u_long *)optp == htonl(TCPOPT_TSTAMP_HDR) &&
- (ti->ti_flags & TH_SYN) == 0) {
- to.to_flag |= TOF_TS;
- to.to_tsval = ntohl(*(u_long *)(optp + 4));
- to.to_tsecr = ntohl(*(u_long *)(optp + 8));
- optp = NULL; /* we've parsed the options */
- }
}
tiflags = ti->ti_flags;
@@ -456,9 +439,8 @@ findpcb:
* Process options if not in LISTEN state,
* else do it below (after getting remote address).
*/
- if (optp && tp->t_state != TCPS_LISTEN)
- tcp_dooptions(tp, optp, optlen, ti,
- &to);
+ if (tp->t_state != TCPS_LISTEN)
+ tcp_dooptions(tp, optp, optlen, ti, &to);
/*
* Header prediction: check for the two common cases
@@ -658,9 +640,7 @@ findpcb:
taop = &tao_noncached;
bzero(taop, sizeof(*taop));
}
- if (optp)
- tcp_dooptions(tp, optp, optlen, ti,
- &to);
+ tcp_dooptions(tp, optp, optlen, ti, &to);
if (iss)
tp->iss = iss;
else
OpenPOWER on IntegriCloud