Commit cffb8f61 authored by Menglong Dong's avatar Menglong Dong Committed by Jakub Kicinski
Browse files

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: default avatarMenglong 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: default avatarJakub Kicinski <kuba@kernel.org>
parent 0169b820
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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;