aboutsummaryrefslogtreecommitdiff
path: root/net/decnet/dn_dev.c
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2007-12-10 15:41:22 +1100
committerPaul Mackerras <paulus@samba.org>2007-12-10 15:41:22 +1100
commitb242a60206881559bb3102110048762422e6b74e (patch)
tree86459efa47b9c3f69d865b4495beede9c4184003 /net/decnet/dn_dev.c
parente1fd18656c2963e383d67b7006c0e06c9c1d9c79 (diff)
parent94545baded0bfbabdc30a3a4cb48b3db479dd6ef (diff)
Merge branch 'linux-2.6'
Diffstat (limited to 'net/decnet/dn_dev.c')
-rw-r--r--net/decnet/dn_dev.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/decnet/dn_dev.c b/net/decnet/dn_dev.c
index 66e266fb590..3bc82dc83b3 100644
--- a/net/decnet/dn_dev.c
+++ b/net/decnet/dn_dev.c
@@ -651,16 +651,18 @@ static int dn_nl_deladdr(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg)
struct dn_dev *dn_db;
struct ifaddrmsg *ifm;
struct dn_ifaddr *ifa, **ifap;
- int err = -EADDRNOTAVAIL;
+ int err;
err = nlmsg_parse(nlh, sizeof(*ifm), tb, IFA_MAX, dn_ifa_policy);
if (err < 0)
goto errout;
+ err = -ENODEV;
ifm = nlmsg_data(nlh);
if ((dn_db = dn_dev_by_index(ifm->ifa_index)) == NULL)
goto errout;
+ err = -EADDRNOTAVAIL;
for (ifap = &dn_db->ifa_list; (ifa = *ifap); ifap = &ifa->ifa_next) {
if (tb[IFA_LOCAL] &&
nla_memcmp(tb[IFA_LOCAL], &ifa->ifa_local, 2))