mirror of
https://github.com/torvalds/linux.git
synced 2025-11-06 03:29:11 +02:00
rtnetlink: return EINVAL when request cannot succeed
A request without interface name/interface index/interface group cannot work. We should return EINVAL Signed-off-by: Florent Fourcot <florent.fourcot@wifirst.fr> Signed-off-by: Brian Baboch <brian.baboch@wifirst.fr> Reviewed-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
parent
dee04163e9
commit
b6177d3240
1 changed files with 1 additions and 1 deletions
|
|
@ -3457,7 +3457,7 @@ static int __rtnl_newlink(struct sk_buff *skb, struct nlmsghdr *nlh,
|
||||||
return rtnl_group_changelink(skb, net,
|
return rtnl_group_changelink(skb, net,
|
||||||
nla_get_u32(tb[IFLA_GROUP]),
|
nla_get_u32(tb[IFLA_GROUP]),
|
||||||
ifm, extack, tb);
|
ifm, extack, tb);
|
||||||
return -ENODEV;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tb[IFLA_MAP] || tb[IFLA_PROTINFO])
|
if (tb[IFLA_MAP] || tb[IFLA_PROTINFO])
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue