From 2b28b3c2769c4b0519889bfad1ebb2db37b13469 Mon Sep 17 00:00:00 2001 From: Alexander Morozov Date: Tue, 11 Aug 2015 17:58:12 -0700 Subject: [PATCH] Always use cgroup root of current process Because for host PID namespace /proc/1/cgroup can point to whole other world of cgroups. Signed-off-by: Alexander Morozov --- libcontainer/cgroups/fs/apply_raw.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libcontainer/cgroups/fs/apply_raw.go b/libcontainer/cgroups/fs/apply_raw.go index f75dab1be..9f50d84b4 100644 --- a/libcontainer/cgroups/fs/apply_raw.go +++ b/libcontainer/cgroups/fs/apply_raw.go @@ -236,7 +236,7 @@ func getCgroupData(c *configs.Cgroup, pid int) (*data, error) { } func (raw *data) parent(subsystem, mountpoint, src string) (string, error) { - initPath, err := cgroups.GetInitCgroupDir(subsystem) + initPath, err := cgroups.GetThisCgroupDir(subsystem) if err != nil { return "", err }