mirror of https://github.com/containers/podman.git
utils: improve error message
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
parent
e2f51eeb06
commit
5174797316
|
|
@ -172,7 +172,7 @@ func moveUnderCgroup(cgroup, subtree string, processes []uint32) error {
|
||||||
if len(processes) > 0 {
|
if len(processes) > 0 {
|
||||||
for _, pid := range processes {
|
for _, pid := range processes {
|
||||||
if _, err := f.Write([]byte(fmt.Sprintf("%d\n", pid))); err != nil {
|
if _, err := f.Write([]byte(fmt.Sprintf("%d\n", pid))); err != nil {
|
||||||
logrus.Warnf("Cannot move process %d to cgroup %q", pid, newCgroup)
|
logrus.Warnf("Cannot move process %d to cgroup %q: %v", pid, newCgroup, err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -185,7 +185,7 @@ func moveUnderCgroup(cgroup, subtree string, processes []uint32) error {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if _, err := f.Write(pid); err != nil {
|
if _, err := f.Write(pid); err != nil {
|
||||||
logrus.Warnf("Cannot move process %s to cgroup %q", string(pid), newCgroup)
|
logrus.Warnf("Cannot move process %s to cgroup %q: %v", string(pid), newCgroup, err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue