From 4c45064939193df4c043f77ecb95cdee6af23a69 Mon Sep 17 00:00:00 2001 From: Ivana Hutarova Varekova Date: Wed, 30 Oct 2013 14:21:33 +0100 Subject: [PATCH] cgroup_create_cgroup: write error on fail In the current version cgroup_create_cgroup returns warning if it fails and can't set some variable. Thus on default configuration there is no information about the problem. This situation happens if the cgconfigparser reads cgconfig.conf. The error message where is the problem is very useful in this case. The patch do the message visible in standard configuration. Signed-off-by: Ivana Hutarova Varekova Acked-by: Peter Schiffer --- src/api.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/api.c b/src/api.c index cd4e5b09..bfd0177b 100644 --- a/src/api.c +++ b/src/api.c @@ -1660,8 +1660,8 @@ int cgroup_create_cgroup(struct cgroup *cgroup, int ignore_ownership) * ignore it specifically if they wish. */ if (error) { - cgroup_warn("Warning: failed to set %s: %s (%d)\n", - path, cgroup_strerror(error), error); + cgroup_err("Error: failed to set %s: %s\n", + path, cgroup_strerror(error)); retval = ECGCANTSETVALUE; continue; } -- 2.47.2