diff options
author | Menglong Dong <dong.menglong@zte.com.cn> | 2020-11-06 07:42:40 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-11-10 01:42:34 +0100 |
commit | cffb8f6177bbfc235e7054a4bb321b126b64205c (patch) | |
tree | cc07ca5bc603c358567095f912194a3019d1c178 /net/ipv4/udp.c | |
parent | bridge: mrp: Use hlist_head instead of list_head for mrp (diff) | |
download | linux-cffb8f6177bbfc235e7054a4bb321b126b64205c.tar.xz linux-cffb8f6177bbfc235e7054a4bb321b126b64205c.zip |
net: udp: remove redundant initialization in udp_send_skb
The initialization for 'err' with 0 is redundant and can be removed,
as it is updated by ip_send_skb and not used before that.
Signed-off-by: Menglong Dong <dong.menglong@zte.com.cn>
Link: https://lore.kernel.org/r/1604644960-48378-4-git-send-email-dong.menglong@zte.com.cn
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/ipv4/udp.c')
-rw-r--r-- | net/ipv4/udp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c index 1e2e73accd11..0d5cd6905749 100644 --- a/net/ipv4/udp.c +++ b/net/ipv4/udp.c @@ -874,7 +874,7 @@ static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4, struct sock *sk = skb->sk; struct inet_sock *inet = inet_sk(sk); struct udphdr *uh; - int err = 0; + int err; int is_udplite = IS_UDPLITE(sk); int offset = skb_transport_offset(skb); int len = skb->len - offset; |