svn commit: r285657 - head/sys/netinet

Patrick Kelsey pkelsey at FreeBSD.org
Fri Jul 17 17:36:34 UTC 2015


Author: pkelsey
Date: Fri Jul 17 17:36:33 2015
New Revision: 285657
URL: https://svnweb.freebsd.org/changeset/base/285657

Log:
  Check TCP timestamp option flag so that the automatic receive buffer
  scaling code does not use an uninitialized timestamp echo reply value
  from the stack when timestamps are not enabled.
  
  Differential Revision: https://reviews.freebsd.org/D3060
  Reviewed by:	hiren
  Approved by:	jmallett (mentor)
  MFC after:	3 days
  Sponsored by:	Norse Corp, Inc.

Modified:
  head/sys/netinet/tcp_input.c

Modified: head/sys/netinet/tcp_input.c
==============================================================================
--- head/sys/netinet/tcp_input.c	Fri Jul 17 16:34:01 2015	(r285656)
+++ head/sys/netinet/tcp_input.c	Fri Jul 17 17:36:33 2015	(r285657)
@@ -1856,6 +1856,7 @@ tcp_do_segment(struct mbuf *m, struct tc
 		 * the buffer to better manage the socket buffer resources.
 		 */
 			if (V_tcp_do_autorcvbuf &&
+			    (to.to_flags & TOF_TS) &&
 			    to.to_tsecr &&
 			    (so->so_rcv.sb_flags & SB_AUTOSIZE)) {
 				if (TSTMP_GT(to.to_tsecr, tp->rfbuf_ts) &&


More information about the svn-src-head mailing list