Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 28 Jun 2022 01:03:08 GMT
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: ad3ad06477d0 - main - blackhole(4): fix operator precedence
Message-ID:  <202206280103.25S1389O070334@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by glebius:

URL: https://cgit.FreeBSD.org/src/commit/?id=ad3ad06477d013371b95af673a9776c62f49a97f

commit ad3ad06477d013371b95af673a9776c62f49a97f
Author:     Gleb Smirnoff <glebius@FreeBSD.org>
AuthorDate: 2022-06-28 00:52:19 +0000
Commit:     Gleb Smirnoff <glebius@FreeBSD.org>
CommitDate: 2022-06-28 00:52:19 +0000

    blackhole(4): fix operator precedence
    
    Fixes:  3ea9a7cf7b09a355cde3a76824809402b99d0892
---
 sys/netinet/tcp_input.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c
index 92858291a05b..a51e62616bea 100644
--- a/sys/netinet/tcp_input.c
+++ b/sys/netinet/tcp_input.c
@@ -919,7 +919,7 @@ findpcb:
 		 * completely ignore the segment and drop it.
 		 */
 		if (((V_blackhole == 1 && (thflags & TH_SYN)) ||
-		    V_blackhole == 2) && (V_blackhole_local ||
+		    V_blackhole == 2) && (V_blackhole_local || (
 #ifdef INET6
 		    isipv6 ? !in6_localaddr(&ip6->ip6_src) :
 #endif
@@ -928,7 +928,7 @@ findpcb:
 #else
 		    true
 #endif
-		    ))
+		    )))
 			goto dropunlock;
 
 		rstreason = BANDLIM_RST_CLOSEDPORT;



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