|
@@ -177,12 +177,12 @@ static inline gid_t from_kgid_munged(struct user_namespace *to, kgid_t kgid)
|
|
|
|
|
|
static inline bool kuid_has_mapping(struct user_namespace *ns, kuid_t uid)
|
|
static inline bool kuid_has_mapping(struct user_namespace *ns, kuid_t uid)
|
|
{
|
|
{
|
|
- return true;
|
|
|
|
|
|
+ return uid_valid(uid);
|
|
}
|
|
}
|
|
|
|
|
|
static inline bool kgid_has_mapping(struct user_namespace *ns, kgid_t gid)
|
|
static inline bool kgid_has_mapping(struct user_namespace *ns, kgid_t gid)
|
|
{
|
|
{
|
|
- return true;
|
|
|
|
|
|
+ return gid_valid(gid);
|
|
}
|
|
}
|
|
|
|
|
|
#endif /* CONFIG_USER_NS */
|
|
#endif /* CONFIG_USER_NS */
|