From b76652fbeb99301ec0b893f56d89537362a05273 Mon Sep 17 00:00:00 2001 From: Kenta Tada Date: Thu, 1 Oct 2020 12:22:12 +0900 Subject: [PATCH] libcontainer: remove `removePath` from cgroups `removePath` is unused as below https://github.com/opencontainers/runc/commit/11fb94965cab5b2a54da9dca50d0e36d0ee36ef0 Signed-off-by: Kenta Tada --- libcontainer/cgroups/fs/fs.go | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/libcontainer/cgroups/fs/fs.go b/libcontainer/cgroups/fs/fs.go index 29690dd62..d4c0e7c20 100644 --- a/libcontainer/cgroups/fs/fs.go +++ b/libcontainer/cgroups/fs/fs.go @@ -427,16 +427,6 @@ func join(path string, pid int) error { return cgroups.WriteCgroupProc(path, pid) } -func removePath(p string, err error) error { - if err != nil { - return err - } - if p != "" { - return os.RemoveAll(p) - } - return nil -} - func (m *manager) GetPaths() map[string]string { m.mu.Lock() defer m.mu.Unlock()