diff options
author | luo penghao <luo.penghao@zte.com.cn> | 2021-12-30 06:26:44 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-12-30 13:29:14 +0000 |
commit | c09f103e89f4554b17c68c3a0a50140fc9133352 (patch) | |
tree | 60c88614a2ce022372fbb7a96842ff4e7e853f58 /net | |
parent | dda0c2e7ed21d7db1568920366e616c6c037b814 (diff) | |
download | linux-c09f103e89f4554b17c68c3a0a50140fc9133352.tar.bz2 |
ethtool: Remove redundant ret assignments
The assignment here will be overwritten, so it should be deleted
The clang_analyzer complains as follows:
net/ethtool/netlink.c:
Value stored to 'ret' is never read
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: luo penghao <luo.penghao@zte.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/ethtool/netlink.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/net/ethtool/netlink.c b/net/ethtool/netlink.c index f09c62302a9a..ea23659fab28 100644 --- a/net/ethtool/netlink.c +++ b/net/ethtool/netlink.c @@ -638,7 +638,6 @@ static void ethnl_default_notify(struct net_device *dev, unsigned int cmd, if (ret < 0) goto err_cleanup; reply_len = ret + ethnl_reply_header_size(); - ret = -ENOMEM; skb = genlmsg_new(reply_len, GFP_KERNEL); if (!skb) goto err_cleanup; |