mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-28 15:20:41 +00:00
fib: Return the correct errno code
[ Upstream commit 59607863c5
]
When kalloc or kmemdup failed, should return ENOMEM rather than ENOBUF.
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
666273bc36
commit
337b6a80b9
1 changed files with 1 additions and 1 deletions
|
@ -928,7 +928,7 @@ static void notify_rule_change(int event, struct fib_rule *rule,
|
|||
{
|
||||
struct net *net;
|
||||
struct sk_buff *skb;
|
||||
int err = -ENOBUFS;
|
||||
int err = -ENOMEM;
|
||||
|
||||
net = ops->fro_net;
|
||||
skb = nlmsg_new(fib_rule_nlmsg_size(ops, rule), GFP_KERNEL);
|
||||
|
|
Loading…
Reference in a new issue