]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
cgroups/cgfsng: fix get_controllers() for cgroup2
authorChristian Brauner <christian.brauner@ubuntu.com>
Tue, 31 Oct 2017 16:06:58 +0000 (17:06 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Thu, 9 Nov 2017 00:24:00 +0000 (01:24 +0100)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/cgroups/cgfsng.c

index 1d0f7b39ee60309fa3809bbb85d804e56dc867d9..472e0766b801eead0eea7908e603d9e8aeaa8a34 100644 (file)
@@ -777,7 +777,7 @@ static char **get_controllers(char **klist, char **nlist, char *line)
        /* cgroup v2 does not have separate mountpoints for controllers */
        if (is_cgroup_v2) {
                must_append_controller(klist, nlist, &aret, "cgroup2");
-               return NULL;
+               return aret;
        }
 
        /* strdup() here for v1 hierarchies. Otherwise strtok_r() will destroy