From b0dd39197e0bb89d843e715bd438a30eefa7cd70 Mon Sep 17 00:00:00 2001 From: Dhaval Giani Date: Tue, 16 Nov 2010 14:29:47 +0100 Subject: [PATCH] v2 [patch 2/6] wrapper.c: correct the return types Steve Grubb was kind enough to do a review at http://article.gmane.org/gmane.comp.lib.libcg.devel/2485 and pointed out that we were checking for unsigned values to be negative. That is of course wrong, and we need to actually be checking integers. Correct the return type so that the check is valid once more. Reported-by: Steve Grubb Signed-off-by: Dhaval Giani Acked-By: Jan Safranek --- src/wrapper.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/wrapper.c b/src/wrapper.c index 83c0030c..4828ea8b 100644 --- a/src/wrapper.c +++ b/src/wrapper.c @@ -436,7 +436,7 @@ int cgroup_set_value_int64(struct cgroup_controller *controller, const char *name, int64_t value) { int i; - unsigned ret; + int ret; if (!controller) return ECGINVAL; @@ -484,7 +484,7 @@ int cgroup_set_value_uint64(struct cgroup_controller *controller, const char *name, u_int64_t value) { int i; - unsigned ret; + int ret; if (!controller) return ECGINVAL; @@ -538,7 +538,7 @@ int cgroup_set_value_bool(struct cgroup_controller *controller, const char *name, bool value) { int i; - unsigned ret; + int ret; if (!controller) return ECGINVAL; -- 2.47.2