Commit 6e822c2c authored by Menglong Dong's avatar Menglong Dong Committed by Jakub Kicinski

net: udp: remove redundant initialization in udp_dump_one

The initialization for 'err' with '-EINVAL' is redundant and
can be removed, as it is updated soon and not used.
Signed-off-by: default avatarMenglong Dong <dong.menglong@zte.com.cn>
Link: https://lore.kernel.org/r/1604644960-48378-2-git-send-email-dong.menglong@zte.com.cnSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent cffb8f61
...@@ -30,7 +30,7 @@ static int udp_dump_one(struct udp_table *tbl, ...@@ -30,7 +30,7 @@ static int udp_dump_one(struct udp_table *tbl,
const struct inet_diag_req_v2 *req) const struct inet_diag_req_v2 *req)
{ {
struct sk_buff *in_skb = cb->skb; struct sk_buff *in_skb = cb->skb;
int err = -EINVAL; int err;
struct sock *sk = NULL; struct sock *sk = NULL;
struct sk_buff *rep; struct sk_buff *rep;
struct net *net = sock_net(in_skb->sk); struct net *net = sock_net(in_skb->sk);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment