git: 7dc73fa66935 - main - tcp: cleanup
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 20 Jul 2025 13:03:05 UTC
The branch main has been updated by tuexen:
URL: https://cgit.FreeBSD.org/src/commit/?id=7dc73fa6693564cecc36cda6788cb21c0c922ced
commit 7dc73fa6693564cecc36cda6788cb21c0c922ced
Author: Michael Tuexen <tuexen@FreeBSD.org>
AuthorDate: 2025-07-20 13:01:00 +0000
Commit: Michael Tuexen <tuexen@FreeBSD.org>
CommitDate: 2025-07-20 13:01:00 +0000
tcp: cleanup
Don't use the variable rstreason temporarily with a different semantic.
No functional change intended.
Reviewed by: Nick Banks
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D51438
---
sys/netinet/tcp_input.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c
index f0921032ef31..1f60c0e07b13 100644
--- a/sys/netinet/tcp_input.c
+++ b/sys/netinet/tcp_input.c
@@ -1055,6 +1055,8 @@ findpcb:
* socket appended to the listen queue in SYN_RECEIVED state.
*/
if ((thflags & (TH_RST|TH_ACK|TH_SYN)) == TH_ACK) {
+ int result;
+
/*
* Parse the TCP options here because
* syncookies need access to the reflected
@@ -1064,8 +1066,8 @@ findpcb:
/*
* NB: syncache_expand() doesn't unlock inp.
*/
- rstreason = syncache_expand(&inc, &to, th, &so, m, port);
- if (rstreason < 0) {
+ result = syncache_expand(&inc, &to, th, &so, m, port);
+ if (result < 0) {
/*
* A failing TCP MD5 signature comparison
* must result in the segment being dropped
@@ -1073,7 +1075,7 @@ findpcb:
* to the sender.
*/
goto dropunlock;
- } else if (rstreason == 0) {
+ } else if (result == 0) {
/*
* No syncache entry, or ACK was not for our
* SYN/ACK. Do our protection against double