aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>2014-01-04 02:32:31 -0500
committerPekka Enberg <penberg@kernel.org>2014-01-13 14:36:34 -0500
commit26e4f2057516f1c457e0e95346a00303f983ad53 (patch)
treeb1523f7150a10b8a486391a8bd8dc17ebb157a81 /mm
parentc65c1877bd6826ce0d9713d76e30a7bed8e49f38 (diff)
slub: Fix possible format string bug.
The "name" is determined at runtime and is parsed as format string. Acked-by: David Rientjes <rientjes@google.com> Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: Pekka Enberg <penberg@kernel.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/slub.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/slub.c b/mm/slub.c
index 367b224f2aa5..a99e9e67c60e 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -5169,7 +5169,7 @@ static int sysfs_slab_add(struct kmem_cache *s)
5169 } 5169 }
5170 5170
5171 s->kobj.kset = slab_kset; 5171 s->kobj.kset = slab_kset;
5172 err = kobject_init_and_add(&s->kobj, &slab_ktype, NULL, name); 5172 err = kobject_init_and_add(&s->kobj, &slab_ktype, NULL, "%s", name);
5173 if (err) { 5173 if (err) {
5174 kobject_put(&s->kobj); 5174 kobject_put(&s->kobj);
5175 return err; 5175 return err;