namei: use current_fsuid() in may_follow_link()
PATCH 1/1 namei: use current_fsuid() in may_follow_link()
Modify may_follow_link() to use current_fsuid()
Signed-off-by Denis Efremov <[email protected]>
--- fs/namei.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/namei.c +1 -1
@@ -958,7 +958,7 @@ static inline int may_follow_link(struct nameidata *nd, const struct inode *inodreturn 0 ;/* Allowed if owner and follower match. */ -if (uid_eq (current_cred ()->fsuid, inode->i_uid)) +if (uid_eq (current_fsuid (), inode->i_uid))return 0 ;/* Allowed if parent directory not sticky and world-writable. */
Signature · 1 line
2.26.2