Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 10 Jun 2009 17:52:10 -0400
From:      John Baldwin <jhb@freebsd.org>
To:        Robert Watson <rwatson@freebsd.org>
Cc:        svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r193941 - head/sys/netinet
Message-ID:  <200906101752.11336.jhb@freebsd.org>
In-Reply-To: <alpine.BSF.2.00.0906102051570.45017@fledge.watson.org>
References:  <200906101827.n5AIRFoR022115@svn.freebsd.org> <alpine.BSF.2.00.0906102051570.45017@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday 10 June 2009 3:52:31 pm Robert Watson wrote:
> 
> On Wed, 10 Jun 2009, John Baldwin wrote:
> 
> >  Change a few members of tcpcb that store cached copies of ticks to be ints
> >  instead of unsigned longs.  This fixes a few overflow edge cases on 64-bit
> >  platforms.  Specifically, if an idle connection receives a packet shortly
> >  before 2^31 clock ticks of uptime (about 25 days with hz=1000) and the keep
> >  alive timer fires after 2^31 clock ticks, the keep alive timer will think
> >  that the connection has been idle for a very long time and will immediately
> >  drop the connection instead of sending a keep alive probe.
> >
> >  Reviewed by:	silby, gnn, lstewart
> >  MFC after:	1 week
> 
> That's pretty subtle even as TCP bugs go, nice work :-).

More of the credit goes to gnn@ and my co-workers.  I had told gnn@ to not worry
about overflow about a week ago because I had just assumed (incorrectly) that
'ticks' and 't_rcvtime' were the same size. :-/

-- 
John Baldwin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906101752.11336.jhb>