fs: change return values from -EACCES to -EPERM
According to SUSv3: [EACCES] Permission denied. An attempt was made to access a file in a way forbidden by its file access permissions. [EPERM] Operation not permitted. An attempt was made to perform an operation limited to processes with appropriate privileges or to the owner of a file or other resource. So -EPERM should be returned if capability checks fails. Strictly speaking this is an API change since the error code user sees is altered. Signed-off-by:Zhao Hongjiang <zhaohongjiang@huawei.com> Acked-by:
Jan Kara <jack@suse.cz> Acked-by:
Steven Whitehouse <swhiteho@redhat.com> Acked-by:
Ian Kent <raven@themaw.net> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk>
Showing
- fs/autofs4/root.c 1 addition, 1 deletionfs/autofs4/root.c
- fs/dlm/config.c 1 addition, 1 deletionfs/dlm/config.c
- fs/gfs2/sys.c 9 additions, 9 deletionsfs/gfs2/sys.c
- fs/ncpfs/ioctl.c 1 addition, 1 deletionfs/ncpfs/ioctl.c
- fs/proc/base.c 3 additions, 3 deletionsfs/proc/base.c
- fs/udf/file.c 1 addition, 1 deletionfs/udf/file.c
Loading
Please register or sign in to comment