patch-2.4.27 linux-2.4.27/fs/attr.c
Next file: linux-2.4.27/fs/buffer.c
Previous file: linux-2.4.27/fs/affs/super.c
Back to the patch index
Back to the overall index
- Lines: 10
- Date:
2004-08-07 16:26:05.963400564 -0700
- Orig file:
linux-2.4.26/fs/attr.c
- Orig date:
2002-02-25 11:38:07.000000000 -0800
diff -urN linux-2.4.26/fs/attr.c linux-2.4.27/fs/attr.c
@@ -33,7 +33,8 @@
/* Make sure caller can chgrp. */
if ((ia_valid & ATTR_GID) &&
- (!in_group_p(attr->ia_gid) && attr->ia_gid != inode->i_gid) &&
+ (current->fsuid != inode->i_uid ||
+ (!in_group_p(attr->ia_gid) && attr->ia_gid != inode->i_gid)) &&
!capable(CAP_CHOWN))
goto error;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)