aboutsummaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2013-08-14 05:35:42 -0400
committerDavid S. Miller <davem@davemloft.net>2013-08-15 04:29:02 -0400
commitfce9b9be89cece975675142a3953bfb5299d195d (patch)
tree286d437c1b3cbd0683eff139878cbd2cc70a3f83 /net/core
parentf36f092065415b75b6be8377ae648c7114e7f099 (diff)
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>
Diffstat (limited to 'net/core')
-rw-r--r--net/core/rtnetlink.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index 0b2972c59b97..242084edb658 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -1867,10 +1867,10 @@ replay:
1867 else 1867 else
1868 err = register_netdevice(dev); 1868 err = register_netdevice(dev);
1869 1869
1870 if (err < 0 && !IS_ERR(dev)) 1870 if (err < 0) {
1871 free_netdev(dev); 1871 free_netdev(dev);
1872 if (err < 0)
1873 goto out; 1872 goto out;
1873 }
1874 1874
1875 err = rtnl_configure_link(dev, ifm); 1875 err = rtnl_configure_link(dev, ifm);
1876 if (err < 0) 1876 if (err < 0)