aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jffs2
diff options
context:
space:
mode:
Diffstat (limited to 'fs/jffs2')
-rw-r--r--fs/jffs2/fs.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/fs/jffs2/fs.c b/fs/jffs2/fs.c
index d2e06f7ea96f..ee192af0b8b0 100644
--- a/fs/jffs2/fs.c
+++ b/fs/jffs2/fs.c
@@ -97,11 +97,7 @@ int jffs2_do_setattr (struct inode *inode, struct iattr *iattr)
97 ri->gid = cpu_to_je16((ivalid & ATTR_GID)?iattr->ia_gid:inode->i_gid); 97 ri->gid = cpu_to_je16((ivalid & ATTR_GID)?iattr->ia_gid:inode->i_gid);
98 98
99 if (ivalid & ATTR_MODE) 99 if (ivalid & ATTR_MODE)
100 if (iattr->ia_mode & S_ISGID && 100 ri->mode = cpu_to_jemode(iattr->ia_mode);
101 !in_group_p(je16_to_cpu(ri->gid)) && !capable(CAP_FSETID))
102 ri->mode = cpu_to_jemode(iattr->ia_mode & ~S_ISGID);
103 else
104 ri->mode = cpu_to_jemode(iattr->ia_mode);
105 else 101 else
106 ri->mode = cpu_to_jemode(inode->i_mode); 102 ri->mode = cpu_to_jemode(inode->i_mode);
107 103