ipv6: remove a useless NULL check
Subsystems (3)
PATCH 1/1 ipv6: remove a useless NULL check
In dev_forward_change(), it is useless to check if idev->dev is NULL, it is always non-NULL here.
Reported-by Fengguang Wu <[email protected]>
Cc David S. Miller <[email protected]>
Signed-off-by Cong Wang <[email protected]>
---
net/ipv6/addrconf.c +1 -1
@@ -607,7 +607,7 @@ static void dev_forward_change(struct inet6_dev *idev) dev = idev->dev;if (idev->cnf.forwarding)dev_disable_lro (dev); -if (dev && (dev->flags &IFF_MULTICAST )) { +if (dev->flags &IFF_MULTICAST ) {if (idev->cnf.forwarding)ipv6_dev_mc_inc (dev, &in6addr_linklocal_allrouters);else
From: Cong Wang <[email protected]>
Date: Mon, 29 Oct 2012 11:43:53 +0800
Quoted 6 lines
In
dev_forward_change(), it is useless to check ifidev->devis NULL, it is always non-NULL here.Reported-by Fengguang Wu <[email protected]>Cc David S. Miller <[email protected]>Signed-off-by Cong Wang <[email protected]>
Applied.