Permalink
Browse files

userns: Fix posix_acl_file_xattr_userns gid conversion

The code needs to be from_kgid(make_kgid(...)...) not
from_kuid(make_kgid(...)...). Doh!

Reported-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
  • Loading branch information...
1 parent 1bbb309 commit ea1fd7776e7ed41ee4ddcff32104db5c7b372309 @ebiederm ebiederm committed Oct 9, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 fs/xattr_acl.c
View
2 fs/xattr_acl.c
@@ -45,7 +45,7 @@ static void posix_acl_fix_xattr_userns(
break;
case ACL_GROUP:
gid = make_kgid(from, le32_to_cpu(entry->e_id));
- entry->e_id = cpu_to_le32(from_kuid(to, uid));
+ entry->e_id = cpu_to_le32(from_kgid(to, gid));
break;
default:
break;

0 comments on commit ea1fd77

Please sign in to comment.