From df18d8c8959bbd9d7b866c6946aa856e462a06b3 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 13 Apr 2011 04:35:34 +0200 Subject: [PATCH] unit: skip default cgroup setup if we have no hierarchy to work on --- src/unit.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/unit.c b/src/unit.c index e19061c5..f50477f8 100644 --- a/src/unit.c +++ b/src/unit.c @@ -1876,6 +1876,9 @@ int unit_add_default_cgroups(Unit *u) { /* Adds in the default cgroups, if they weren't specified * otherwise. */ + if (!u->meta.manager->cgroup_hierarchy) + return 0; + if ((r = unit_add_one_default_cgroup(u, NULL)) < 0) return r; -- 2.39.5