chiark / gitweb /
bus-control: Fix cgroup handling
[elogind.git] / src / libsystemd / sd-bus / bus-control.c
index 076bbce6b1a2c8438eb746cf8907fa5c4169b868..ad372f6772c5b8a3b795f5636ad4ac1c96eac30c 100644 (file)
@@ -495,11 +495,9 @@ static int bus_get_owner_kdbus(
                                         goto fail;
                                 }
 
-                                if (!bus->cgroup_root) {
-                                        r = cg_get_root_path(&bus->cgroup_root);
-                                        if (r < 0)
-                                                goto fail;
-                                }
+                                r = bus_get_root_path(bus);
+                                if (r < 0)
+                                        goto fail;
 
                                 c->cgroup_root = strdup(bus->cgroup_root);
                                 if (!c->cgroup_root) {