git: 6d3e3afbf96e - main - tcp: remove redundant assignments
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 06 Sep 2026 14:06:34 UTC
The branch main has been updated by tuexen:
URL: https://cgit.FreeBSD.org/src/commit/?id=6d3e3afbf96e921554b5f97bb52b557adcd01098
commit 6d3e3afbf96e921554b5f97bb52b557adcd01098
Author: Michael Tuexen <tuexen@FreeBSD.org>
AuthorDate: 2026-09-06 14:01:21 +0000
Commit: Michael Tuexen <tuexen@FreeBSD.org>
CommitDate: 2026-09-06 14:05:40 +0000
tcp: remove redundant assignments
Since the struct inpcb in embedded in the struct tcpcb, the
relationship can't change. So there is no need to reassign the tp
anymore.
No functional change intended.
Reported by: Hannes Elfert
Reviewed by: glebius
MFC after: 1 week
MFC to: stable/15
Differential Revision: https://reviews.freebsd.org/D59384
---
sys/netinet/tcp_usrreq.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/sys/netinet/tcp_usrreq.c b/sys/netinet/tcp_usrreq.c
index 9c61734b26c9..33f62a73ce2c 100644
--- a/sys/netinet/tcp_usrreq.c
+++ b/sys/netinet/tcp_usrreq.c
@@ -1592,7 +1592,6 @@ tcp_fill_info(const struct tcpcb *tp, struct tcp_info *ti)
*/
#define INP_WLOCK_RECHECK_CLEANUP(inp, cleanup) do { \
INP_WLOCK(inp); \
- tp = intotcpcb(inp); \
if (tp->t_flags & TF_DISCONNECTED) { \
INP_WUNLOCK(inp); \
cleanup; \
@@ -2401,7 +2400,6 @@ unlock_and_done:
break;
case SOPT_GET:
- tp = intotcpcb(inp);
switch (sopt->sopt_name) {
#if defined(IPSEC_SUPPORT) || defined(TCP_SIGNATURE)
case TCP_MD5SIG: