summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2021-06-14 20:18:40 +0200
committerGiuseppe Scrivano <gscrivan@redhat.com>2021-06-16 08:49:56 +0200
commit51747973169cfba865a762df2d6098f5befa25a8 (patch)
tree0cbd7292861be8c8167cc704dfc7553e6f302e16
parente2f51eeb0693eda026fa509a9decfbdd7e0b74a8 (diff)
downloadpodman-51747973169cfba865a762df2d6098f5befa25a8.tar.gz
podman-51747973169cfba865a762df2d6098f5befa25a8.tar.bz2
podman-51747973169cfba865a762df2d6098f5befa25a8.zip
utils: improve error message
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
-rw-r--r--utils/utils_supported.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/utils/utils_supported.go b/utils/utils_supported.go
index ad6192255..8e2966bfc 100644
--- a/utils/utils_supported.go
+++ b/utils/utils_supported.go
@@ -172,7 +172,7 @@ func moveUnderCgroup(cgroup, subtree string, processes []uint32) error {
if len(processes) > 0 {
for _, pid := range processes {
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 {
@@ -185,7 +185,7 @@ func moveUnderCgroup(cgroup, subtree string, processes []uint32) error {
continue
}
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)
}
}
}