From: Lennart Poettering Date: Tue, 1 Sep 2015 16:36:28 +0000 (+0200) Subject: cgroup: the root cgroup is always populated X-Git-Tag: v226~54^2~4 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6fd66507378bd8706cba38f82167a54d9d116e43;p=thirdparty%2Fsystemd.git cgroup: the root cgroup is always populated --- diff --git a/src/basic/cgroup-util.c b/src/basic/cgroup-util.c index 61681ada8db..98adace55a5 100644 --- a/src/basic/cgroup-util.c +++ b/src/basic/cgroup-util.c @@ -918,6 +918,10 @@ int cg_is_empty_recursive(const char *controller, const char *path) { assert(path); + /* The root cgroup is always populated */ + if (controller && (isempty(path) || path_equal(path, "/"))) + return 0; + r = cg_is_empty(controller, path); if (r <= 0) return r;