net: ipv6: rpl_iptunnel: remove redundant assignments to variable err
authorColin Ian King <colin.king@canonical.com>
Thu, 2 Apr 2020 10:18:59 +0000 (11:18 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Apr 2020 13:57:34 +0000 (06:57 -0700)
The variable err is being initialized with a value that is never
read and it is being updated later with a new value.  The initialization
is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/rpl_iptunnel.c

index a49ddc6cd020dce6005faddbebfc29a30501acf1..c3ececd7cfc1645b7b8308c754ba0f83e0c3d120 100644 (file)
@@ -210,7 +210,7 @@ static int rpl_output(struct net *net, struct sock *sk, struct sk_buff *skb)
        struct dst_entry *orig_dst = skb_dst(skb);
        struct dst_entry *dst = NULL;
        struct rpl_lwt *rlwt;
-       int err = -EINVAL;
+       int err;
 
        rlwt = rpl_lwt_lwtunnel(orig_dst->lwtstate);