Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 362610
b: refs/heads/master
c: e3211c1
h: refs/heads/master
v: v3
  • Loading branch information
Andy Lutomirski committed Apr 15, 2013
1 parent a4e8dc2 commit 269c9ae
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6708075f104c3c9b04b23336bb0366ca30c3931b
refs/heads/master: e3211c120a85b792978bcb4be7b2886df18d27f0
4 changes: 2 additions & 2 deletions trunk/kernel/user_namespace.c
Original file line number Diff line number Diff line change
Expand Up @@ -797,12 +797,12 @@ static bool new_idmap_permitted(const struct file *file,
u32 id = new_map->extent[0].lower_first;
if (cap_setid == CAP_SETUID) {
kuid_t uid = make_kuid(ns->parent, id);
if (uid_eq(uid, current_fsuid()))
if (uid_eq(uid, file->f_cred->fsuid))
return true;
}
else if (cap_setid == CAP_SETGID) {
kgid_t gid = make_kgid(ns->parent, id);
if (gid_eq(gid, current_fsgid()))
if (gid_eq(gid, file->f_cred->fsgid))
return true;
}
}
Expand Down

0 comments on commit 269c9ae

Please sign in to comment.