* [PATCH nf-next v2] netfilter: osf: remove unreachable break in nf_osf_ttl()
@ 2026-08-21 9:50 Linkui Xiao
0 siblings, 0 replies; only message in thread
From: Linkui Xiao @ 2026-08-21 9:50 UTC (permalink / raw)
To: pablo, fw, phil, davem, edumazet, kuba, pabeni, horms
Cc: netfilter-devel, coreteam, netdev, Linkui Xiao
From: Linkui Xiao <xiaolinkui@kylinos.cn>
In nf_osf_ttl(), the break statement after return in NF_OSF_TTL_TRUE
case is unreachable dead‑code. The return statement exits the function
immediately, so break will never execute.
Remove the useless break, no functional change.
Signed-off-by: Linkui Xiao <xiaolinkui@kylinos.cn>
---
v2: Rebase onto nf-next.
net/netfilter/nfnetlink_osf.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/netfilter/nfnetlink_osf.c b/net/netfilter/nfnetlink_osf.c
index 92002079f8ea..a3f855905d52 100644
--- a/net/netfilter/nfnetlink_osf.c
+++ b/net/netfilter/nfnetlink_osf.c
@@ -36,7 +36,6 @@ static inline int nf_osf_ttl(const struct sk_buff *skb,
switch (ttl_check) {
case NF_OSF_TTL_TRUE:
return ip->ttl == f_ttl;
- break;
case NF_OSF_TTL_NOCHECK:
return 1;
case NF_OSF_TTL_LESS:
--
2.25.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-08-21 9:51 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-21 9:50 [PATCH nf-next v2] netfilter: osf: remove unreachable break in nf_osf_ttl() Linkui Xiao
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox