[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20211104062621.2643-1-luo.penghao@zte.com.cn>
Date: Thu, 4 Nov 2021 06:26:21 +0000
From: cgel.zte@...il.com
To: Steffen Klassert <steffen.klassert@...unet.com>
Cc: Herbert Xu <herbert@...dor.apana.org.au>,
"David S . Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, luo penghao <luo.penghao@....com.cn>,
Zeal Robot <zealci@....com.cn>
Subject: [PATCH linux-next] xfrm: Remove duplicate assignment
From: luo penghao <luo.penghao@....com.cn>
The statement in the switch is repeated with the statement at the
beginning of the while loop, so this statement is meaningless.
The clang_analyzer complains as follows:
net/xfrm/xfrm_policy.c:3392:2 warning:
Value stored to 'exthdr' is never read
Reported-by: Zeal Robot <zealci@....com.cn>
Signed-off-by: luo penghao <luo.penghao@....com.cn>
---
net/xfrm/xfrm_policy.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/xfrm/xfrm_policy.c b/net/xfrm/xfrm_policy.c
index 7f881f5..e8a31b9 100644
--- a/net/xfrm/xfrm_policy.c
+++ b/net/xfrm/xfrm_policy.c
@@ -3389,7 +3389,6 @@ decode_session6(struct sk_buff *skb, struct flowi *fl, bool reverse)
case NEXTHDR_DEST:
offset += ipv6_optlen(exthdr);
nexthdr = exthdr->nexthdr;
- exthdr = (struct ipv6_opt_hdr *)(nh + offset);
break;
case IPPROTO_UDP:
case IPPROTO_UDPLITE:
--
2.15.2
Powered by blists - more mailing lists