path now returns the IsNotFound error

This error is not propogated up to the caller and needs to be handled at
the site where d.path() is called.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
Michael Crosby 2015-03-23 11:32:09 -07:00
parent 5c6332687d
commit c099a20eb8
1 changed files with 3 additions and 4 deletions

View File

@ -99,12 +99,11 @@ func (m *Manager) Apply(pid int) error {
// created then join consists of writing the process pids to cgroup.procs
p, err := d.path(name)
if err != nil {
if cgroups.IsNotFound(err) {
continue
}
return err
}
if !cgroups.PathExists(p) {
continue
}
paths[name] = p
}
m.Paths = paths