Skip to content

Commit

Permalink
JFS: Allow security.* xattrs to be set on symlinks
Browse files Browse the repository at this point in the history
All of the different xattr namespaces have different rules.
user.* and ACL's are not allowed on symlinks, and since these were the
first xattrs implemented, I assumed there was no need to support xattrs
on symlinks.  This one-line patch should fix it.

Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
  • Loading branch information
Dave Kleikamp committed Jul 13, 2005
1 parent f7f2475 commit 6211502
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/jfs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -781,7 +781,7 @@ static int can_set_xattr(struct inode *inode, const char *name,
if (IS_RDONLY(inode))
return -EROFS;

if (IS_IMMUTABLE(inode) || IS_APPEND(inode) || S_ISLNK(inode->i_mode))
if (IS_IMMUTABLE(inode) || IS_APPEND(inode))
return -EPERM;

if(strncmp(name, XATTR_SYSTEM_PREFIX, XATTR_SYSTEM_PREFIX_LEN) == 0)
Expand Down

0 comments on commit 6211502

Please sign in to comment.