rtnetlink: remove an unneeded test

We know that "dev" is a valid pointer at this point, so we can remove
the test and clean up a little.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Dan Carpenter 2013-08-14 12:35:42 +03:00 committed by David S. Miller
parent f36f092065
commit fce9b9be89

View File

@ -1867,10 +1867,10 @@ replay:
else
err = register_netdevice(dev);
if (err < 0 && !IS_ERR(dev))
if (err < 0) {
free_netdev(dev);
if (err < 0)
goto out;
}
err = rtnl_configure_link(dev, ifm);
if (err < 0)