Commit 600a328f authored by Lennart Poettering's avatar Lennart Poettering

mount: do not try to mount disable cgroup controllers

https://bugzilla.redhat.com/show_bug.cgi?id=655222
parent c8b2e52c
......@@ -28,7 +28,7 @@
* set_put(), hashmap_put() return values check. i.e. == 0 doesn't free()!
* chkconfig/systemd-install glue
* chkconfig/systemd enable glue
* io priority during initialization
......
......@@ -138,8 +138,9 @@ static int mount_cgroup_controllers(void) {
for (;;) {
MountPoint p;
char *controller, *where;
int enabled = false;
if (fscanf(f, "%ms %*i %*i %*i", &controller) != 1) {
if (fscanf(f, "%ms %*i %*i %i", &controller, &enabled) != 1) {
if (feof(f))
break;
......@@ -149,6 +150,11 @@ static int mount_cgroup_controllers(void) {
goto finish;
}
if (!enabled) {
free(controller);
continue;
}
if (asprintf(&where, "/sys/fs/cgroup/%s", controller) < 0) {
free(controller);
r = -ENOMEM;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment