From 800c5e585c46e34fce8629b97b63c51409dfb8bb Mon Sep 17 00:00:00 2001 From: Tetsuo Handa Date: Mon, 9 Nov 2009 09:12:15 +0900 Subject: [PATCH] --- yaml --- r: 170032 b: refs/heads/master c: 86b1bc68e2f4244e4ea5db5458df9d19259fbb30 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/security/tomoyo/tomoyo.c | 10 +--------- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/[refs] b/[refs] index 3bb9e9bb5c33..48adedbea771 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 50469619999a0bc2ba8fa1365dc443b7aed190af +refs/heads/master: 86b1bc68e2f4244e4ea5db5458df9d19259fbb30 diff --git a/trunk/security/tomoyo/tomoyo.c b/trunk/security/tomoyo/tomoyo.c index 9548a0984cc4..3f93bb91768b 100644 --- a/trunk/security/tomoyo/tomoyo.c +++ b/trunk/security/tomoyo/tomoyo.c @@ -122,15 +122,7 @@ static char *tomoyo_sysctl_path(struct ctl_table *table) *--end = '\0'; buflen--; while (table) { - char num[32]; - const char *sp = table->procname; - - if (!sp) { - memset(num, 0, sizeof(num)); - snprintf(num, sizeof(num) - 1, "=%d=", table->ctl_name); - sp = num; - } - if (tomoyo_prepend(&end, &buflen, sp) || + if (tomoyo_prepend(&end, &buflen, table->procname) || tomoyo_prepend(&end, &buflen, "/")) goto out; table = table->parent;