Always join fs.Cpuset reguardless of value

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
Michael Crosby 2014-11-17 19:05:58 -08:00
parent 9c7bd7cd9e
commit 75093be3c9
1 changed files with 4 additions and 10 deletions

View File

@ -14,17 +14,11 @@ type CpusetGroup struct {
} }
func (s *CpusetGroup) Set(d *data) error { func (s *CpusetGroup) Set(d *data) error {
// we don't want to join this cgroup unless it is specified dir, err := d.path("cpuset")
if d.c.CpusetCpus != "" { if err != nil {
dir, err := d.path("cpuset") return err
if err != nil {
return err
}
return s.SetDir(dir, d.c.CpusetCpus, d.pid)
} }
return s.SetDir(dir, d.c.CpusetCpus, d.pid)
return nil
} }
func (s *CpusetGroup) Remove(d *data) error { func (s *CpusetGroup) Remove(d *data) error {