path: root/security/security.c
diff options
authorMiklos Szeredi <mszeredi@suse.cz>2008-07-01 15:01:28 +0200
committerAl Viro <viro@zeniv.linux.org.uk>2008-07-26 20:53:27 -0400
commitb1da47e29e467f1ec36dc78d009bfb109fd533c7 (patch)
tree13d72e54e6b7d9bbb0e48158c84bcb26561b0ecb /security/security.c
parente9b76fedc61235da80b6b7f81dfd67ec224dfb49 (diff)
[patch 3/4] fat: dont call notify_change
The FAT_IOCTL_SET_ATTRIBUTES ioctl() calls notify_change() to change the file mode before changing the inode attributes. Replace with explicit calls to security_inode_setattr(), fat_setattr() and fsnotify_change(). This is equivalent to the original. The reason it is needed, is that later in the series we move the immutable check into notify_change(). That would break the FAT_IOCTL_SET_ATTRIBUTES ioctl, as it needs to perform the mode change regardless of the immutability of the file. [Fix error if fat is built as a module. Thanks to OGAWA Hirofumi for noticing.] Signed-off-by: Miklos Szeredi <mszeredi@suse.cz> Acked-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'security/security.c')
1 files changed, 1 insertions, 0 deletions
diff --git a/security/security.c b/security/security.c
index 78ed3ffde24..ff706872775 100644
--- a/security/security.c
+++ b/security/security.c
@@ -442,6 +442,7 @@ int security_inode_setattr(struct dentry *dentry, struct iattr *attr)
return 0;
return security_ops->inode_setattr(dentry, attr);
int security_inode_getattr(struct vfsmount *mnt, struct dentry *dentry)