mirror of
https://github.com/torvalds/linux.git
synced 2026-11-06 21:58:01 +01:00
cgroup: namespace: Drop BUG_ON() in copy_cgroup_ns()
The sole caller, create_new_namespaces(), always passes a valid cgroup namespace pointer from the task's nsproxy. The other copy_*_ns() helpers, e.g. copy_time_ns() and copy_pid_ns(), don't perform such a check either. Drop the BUG_ON() for consistency with them. Signed-off-by: Shaojie Sun <sunshaojie@kylinos.cn> Reviewed-by: Tao Cui <cuitao@kylinos.cn> Signed-off-by: Tejun Heo <tj@kernel.org>
This commit is contained in:
parent
940de590b8
commit
93fccdb045
|
|
@ -53,8 +53,6 @@ struct cgroup_namespace *copy_cgroup_ns(u64 flags,
|
|||
struct ucounts *ucounts;
|
||||
struct css_set *cset;
|
||||
|
||||
BUG_ON(!old_ns);
|
||||
|
||||
if (!(flags & CLONE_NEWCGROUP)) {
|
||||
get_cgroup_ns(old_ns);
|
||||
return old_ns;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user