projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9119570
)
net: return correct error code
author
liuguoqiang
<liuguoqiang@uniontech.com>
Mon, 15 Nov 2021 08:14:48 +0000
(16:14 +0800)
committer
David S. Miller
<davem@davemloft.net>
Mon, 15 Nov 2021 14:22:12 +0000
(14:22 +0000)
When kmemdup called failed and register_net_sysctl return NULL, should
return ENOMEM instead of ENOBUFS
Signed-off-by: liuguoqiang <liuguoqiang@uniontech.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/devinet.c
patch
|
blob
|
history
diff --git
a/net/ipv4/devinet.c
b/net/ipv4/devinet.c
index
ec73a0d
..
323e622
100644
(file)
--- a/
net/ipv4/devinet.c
+++ b/
net/ipv4/devinet.c
@@
-2591,7
+2591,7
@@
static int __devinet_sysctl_register(struct net *net, char *dev_name,
free:
kfree(t);
out:
- return -ENO
BUFS
;
+ return -ENO
MEM
;
}
static void __devinet_sysctl_unregister(struct net *net,