summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorYaowei Bai <baiyaowei@cmss.chinamobile.com>2015-11-19 21:00:12 +0800
committerAl Viro <viro@zeniv.linux.org.uk>2015-12-06 21:17:14 -0500
commitd37177bacdf7cbcdb23a513cbb475fa241f8083c (patch)
tree5178cef19a7ff10789085da992b1aa7e25ce166f /include
parent0e3ef1fe453c9f29c30d040cd2559c5cac724e93 (diff)
downloadlwn-d37177bacdf7cbcdb23a513cbb475fa241f8083c.tar.gz
lwn-d37177bacdf7cbcdb23a513cbb475fa241f8083c.zip
fs/attr.c: is_sxid can be boolean
This patch makes is_sxid return bool to improve readability due to this particular function only using either one or zero as its return value. No functional change. Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include')
-rw-r--r--include/linux/fs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 6b33ac447612..bd1447661e3c 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -2963,7 +2963,7 @@ int __init get_filesystem_list(char *buf);
#define OPEN_FMODE(flag) ((__force fmode_t)(((flag + 1) & O_ACCMODE) | \
(flag & __FMODE_NONOTIFY)))
-static inline int is_sxid(umode_t mode)
+static inline bool is_sxid(umode_t mode)
{
return (mode & S_ISUID) || ((mode & S_ISGID) && (mode & S_IXGRP));
}