Commit 6524cd5e authored by Wojciech Tyczynski's avatar Wojciech Tyczynski

Merge pull request #11562 from MikaelCluseau/master

realContainerGC reports warning when err is nil
parents 56444bfb aff10f57
...@@ -207,7 +207,7 @@ func (cgc *realContainerGC) removeOldestN(containers []containerGCInfo, toRemove ...@@ -207,7 +207,7 @@ func (cgc *realContainerGC) removeOldestN(containers []containerGCInfo, toRemove
} }
symlinkPath := dockertools.LogSymlink(cgc.containerLogsDir, containers[i].podNameWithNamespace, containers[i].containerName, containers[i].id) symlinkPath := dockertools.LogSymlink(cgc.containerLogsDir, containers[i].podNameWithNamespace, containers[i].containerName, containers[i].id)
err = os.Remove(symlinkPath) err = os.Remove(symlinkPath)
if !os.IsNotExist(err) { if err != nil && !os.IsNotExist(err) {
glog.Warningf("Failed to remove container %q log symlink %q: %v", containers[i].name, symlinkPath, err) glog.Warningf("Failed to remove container %q log symlink %q: %v", containers[i].name, symlinkPath, err)
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment