summaryrefslogtreecommitdiffstats
path: root/net/netrom/af_netrom.c
diff options
context:
space:
mode:
authorZhao Hongjiang <zhaohongjiang@huawei.com>2012-09-21 00:37:25 +0200
committerDavid S. Miller <davem@davemloft.net>2012-09-21 19:58:08 +0200
commitbf5b30b8a4416de04f1ac1196281ddb318669464 (patch)
treea96a8280047830630b54aa82c568f7a22e8f0ba1 /net/netrom/af_netrom.c
parentMerge branch 'fixes-for-3.6' of git://gitorious.org/linux-can/linux-can (diff)
downloadlinux-bf5b30b8a4416de04f1ac1196281ddb318669464.tar.xz
linux-bf5b30b8a4416de04f1ac1196281ddb318669464.zip
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/af_netrom.c')
-rw-r--r--net/netrom/af_netrom.c2
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)
if (!capable(CAP_NET_BIND_SERVICE)) {
dev_put(dev);
release_sock(sk);
- return -EACCES;
+ return -EPERM;
}
nr->user_addr = addr->fsa_digipeater[0];
nr->source_addr = addr->fsa_ax25.sax25_call;