projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b923cda
)
net: Return the correct errno code
author
Zheng Yongjun
<zhengyongjun3@huawei.com>
Tue, 1 Jun 2021 14:14:07 +0000
(22:14 +0800)
committer
David S. Miller
<davem@davemloft.net>
Wed, 2 Jun 2021 00:02:15 +0000
(17:02 -0700)
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>
net/ipv4/af_inet.c
patch
|
blob
|
history
diff --git
a/net/ipv4/af_inet.c
b/net/ipv4/af_inet.c
index
d9bccad
..
750f388
100644
(file)
--- a/
net/ipv4/af_inet.c
+++ b/
net/ipv4/af_inet.c
@@
-318,7
+318,7
@@
lookup_protocol:
WARN_ON(!answer_prot->slab);
- err = -ENO
BUFS
;
+ err = -ENO
MEM
;
sk = sk_alloc(net, PF_INET, GFP_KERNEL, answer_prot, kern);
if (!sk)
goto out;