summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsam <sam@FreeBSD.org>2003-11-08 22:57:13 +0000
committersam <sam@FreeBSD.org>2003-11-08 22:57:13 +0000
commitb84b4aa531ee10b022780d62bdc166be0f3551d6 (patch)
treed0a475aea6ec9daaef4cc4da83154580d3ad6feb
parent8a7d4d7c73e7ebeb2a71afa9caae8128a404a921 (diff)
downloadFreeBSD-src-b84b4aa531ee10b022780d62bdc166be0f3551d6.zip
FreeBSD-src-b84b4aa531ee10b022780d62bdc166be0f3551d6.tar.gz
use local values instead of chasing pointers
Supported by: FreeBSD Foundation
-rw-r--r--sys/netinet/tcp_timer.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/netinet/tcp_timer.c b/sys/netinet/tcp_timer.c
index 12b63a5..1a253ab 100644
--- a/sys/netinet/tcp_timer.c
+++ b/sys/netinet/tcp_timer.c
@@ -353,8 +353,7 @@ tcp_timer_keep(xtp)
tcpstat.tcps_keeptimeo++;
if (tp->t_state < TCPS_ESTABLISHED)
goto dropit;
- if ((always_keepalive ||
- tp->t_inpcb->inp_socket->so_options & SO_KEEPALIVE) &&
+ if ((always_keepalive || inp->inp_socket->so_options & SO_KEEPALIVE) &&
tp->t_state <= TCPS_CLOSING) {
if ((ticks - tp->t_rcvtime) >= tcp_keepidle + tcp_maxidle)
goto dropit;
@@ -383,7 +382,7 @@ tcp_timer_keep(xtp)
callout_reset(tp->tt_keep, tcp_keepidle, tcp_timer_keep, tp);
#ifdef TCPDEBUG
- if (tp->t_inpcb->inp_socket->so_options & SO_DEBUG)
+ if (inp->inp_socket->so_options & SO_DEBUG)
tcp_trace(TA_USER, ostate, tp, (void *)0, (struct tcphdr *)0,
PRU_SLOWTIMO);
#endif
OpenPOWER on IntegriCloud