diff options
author | Zhao Hongjiang <zhaohongjiang@huawei.com> | 2012-09-20 18:37:25 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-09-21 13:58:08 -0400 |
commit | bf5b30b8a4416de04f1ac1196281ddb318669464 (patch) | |
tree | a96a8280047830630b54aa82c568f7a22e8f0ba1 /net/netrom | |
parent | e0c7a4a1a6c4ace4a176b95cb5089f55452c625e (diff) |
net: change return values from -EACCES to -EPERM
Change return value from -EACCES to -EPERM when the permission check fails.
Signed-off-by: Zhao Hongjiang <zhaohongjiang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/netrom')
-rw-r--r-- | net/netrom/af_netrom.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c index 1b9024ee963c..7261eb81974f 100644 --- a/net/netrom/af_netrom.c +++ b/net/netrom/af_netrom.c | |||
@@ -601,7 +601,7 @@ static int nr_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len) | |||
601 | if (!capable(CAP_NET_BIND_SERVICE)) { | 601 | if (!capable(CAP_NET_BIND_SERVICE)) { |
602 | dev_put(dev); | 602 | dev_put(dev); |
603 | release_sock(sk); | 603 | release_sock(sk); |
604 | return -EACCES; | 604 | return -EPERM; |
605 | } | 605 | } |
606 | nr->user_addr = addr->fsa_digipeater[0]; | 606 | nr->user_addr = addr->fsa_digipeater[0]; |
607 | nr->source_addr = addr->fsa_ax25.sax25_call; | 607 | nr->source_addr = addr->fsa_ax25.sax25_call; |