summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKen'ichi Ohmichi <oomichi@mxs.nes.nec.co.jp>2009-06-30 09:02:37 +0900
committerDhaval Giani <dhaval@linux.vnet.ibm.com>2009-06-30 13:28:35 +0530
commit8a96474be4f14482d171645ee9710b3ac318c14a (patch)
treee02458543aee1ef5d4c07a3fb43a65e0a83dc0e1
parentd0992aa5920177af702198348de0db32291fcb8c (diff)
downloadlibcg-8a96474be4f14482d171645ee9710b3ac318c14a.tar.gz
libcg-8a96474be4f14482d171645ee9710b3ac318c14a.tar.xz
libcg-8a96474be4f14482d171645ee9710b3ac318c14a.zip
Fix cgroup_find_matching_rule() call.
Hi, If compiling the latest code (8cc1d9743201cb9ae9a5286c898b9d47e318ed46), the following warning messages are printed. The problem is due to invalid call of cgroup_find_matching_rule_uid_gid(). Instead of this function call, cgroup_find_matching_rule() should be called as "[PATCH-v6 03/11] Add the key "process name" to find a matching rule.". $ make [snip] api.c: In function 'cgroup_change_cgroup_flags': api.c:1994: warning: passing argument 3 of 'cgroup_find_matching_rule_uid_gid' from incompatible pointer type api.c: At top level: api.c:1923: warning: 'cgroup_find_matching_rule' defined but not used [snip] $ * Reference: "[PATCH-v6 03/11] Add the key "process name" to find a matching rule." http://sourceforge.net/mailarchive/message.php?msg_name=4A44617E.9060002%40mxs.nes.nec.co.jp Signed-off-by: Ken'ichi Ohmichi <oomichi@mxs.nes.nec.co.jp> Signed-off-by: Dhaval Giani <dhaval@linux.vnet.ibm.com>
-rw-r--r--src/api.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/api.c b/src/api.c
index ee299c6..25011bb 100644
--- a/src/api.c
+++ b/src/api.c
@@ -1991,7 +1991,7 @@ int cgroup_change_cgroup_flags(const uid_t uid, const gid_t gid,
tmp = trl.head;
} else {
/* Find the first matching rule in the cached list. */
- tmp = cgroup_find_matching_rule_uid_gid(uid, gid, procname);
+ tmp = cgroup_find_matching_rule(uid, gid, procname);
if (!tmp) {
cgroup_dbg("No rule found to match PID: %d, UID: %d, "
"GID: %d\n", pid, uid, gid);