mirror of
https://github.com/morgan9e/systemd
synced 2026-04-14 00:14:32 +09:00
cgroup-util: drop 'controller' argument from cg_get_path()
The argument is not used anymore. Let's drop it.
This commit is contained in:
@@ -67,7 +67,7 @@ int cg_path_open(const char *path) {
|
||||
_cleanup_free_ char *fs = NULL;
|
||||
int r;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, /* suffix= */ NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix= */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -137,7 +137,7 @@ int cg_enumerate_processes(const char *path, FILE **ret) {
|
||||
|
||||
assert(ret);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, "cgroup.procs", &fs);
|
||||
r = cg_get_path(path, "cgroup.procs", &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -241,7 +241,7 @@ int cg_enumerate_subgroups(const char *path, DIR **ret) {
|
||||
|
||||
/* This is not recursive! */
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -444,7 +444,7 @@ int cg_kill_kernel_sigkill(const char *path) {
|
||||
if (!cg_kill_supported())
|
||||
return -EOPNOTSUPP;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, "cgroup.kill", &killfile);
|
||||
r = cg_get_path(path, "cgroup.kill", &killfile);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -455,7 +455,7 @@ int cg_kill_kernel_sigkill(const char *path) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
int cg_get_path(const char *controller, const char *path, const char *suffix, char **ret) {
|
||||
int cg_get_path(const char *path, const char *suffix, char **ret) {
|
||||
char *t;
|
||||
|
||||
assert(ret);
|
||||
@@ -463,10 +463,7 @@ int cg_get_path(const char *controller, const char *path, const char *suffix, ch
|
||||
if (isempty(path))
|
||||
path = TAKE_PTR(suffix);
|
||||
|
||||
if (controller)
|
||||
t = path_join("/sys/fs/cgroup", path, suffix);
|
||||
else
|
||||
t = path_join(path, suffix);
|
||||
t = path_join("/sys/fs/cgroup", path, suffix);
|
||||
if (!t)
|
||||
return -ENOMEM;
|
||||
|
||||
@@ -482,7 +479,7 @@ int cg_set_xattr(const char *path, const char *name, const void *value, size_t s
|
||||
assert(name);
|
||||
assert(value || size <= 0);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -496,7 +493,7 @@ int cg_get_xattr(const char *path, const char *name, char **ret, size_t *ret_siz
|
||||
assert(path);
|
||||
assert(name);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -510,7 +507,7 @@ int cg_get_xattr_bool(const char *path, const char *name) {
|
||||
assert(path);
|
||||
assert(name);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -524,7 +521,7 @@ int cg_remove_xattr(const char *path, const char *name) {
|
||||
assert(path);
|
||||
assert(name);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -691,7 +688,7 @@ int cg_split_spec(const char *spec, char **ret_controller, char **ret_path) {
|
||||
}
|
||||
|
||||
int cg_mangle_path(const char *path, char **ret) {
|
||||
_cleanup_free_ char *c = NULL, *p = NULL;
|
||||
_cleanup_free_ char *p = NULL;
|
||||
int r;
|
||||
|
||||
assert(path);
|
||||
@@ -702,11 +699,11 @@ int cg_mangle_path(const char *path, char **ret) {
|
||||
return path_simplify_alloc(path, ret);
|
||||
|
||||
/* Otherwise, treat it as cg spec */
|
||||
r = cg_split_spec(path, &c, &p);
|
||||
r = cg_split_spec(path, /* ret_controller = */ NULL, &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
return cg_get_path(c ?: SYSTEMD_CGROUP_CONTROLLER, p ?: "/", NULL, ret);
|
||||
return cg_get_path(p, /* suffix = */ NULL, ret);
|
||||
}
|
||||
|
||||
int cg_get_root_path(char **ret_path) {
|
||||
@@ -1439,7 +1436,7 @@ int cg_is_threaded(const char *path) {
|
||||
_cleanup_strv_free_ char **v = NULL;
|
||||
int r;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, "cgroup.type", &fs);
|
||||
r = cg_get_path(path, "cgroup.type", &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1464,7 +1461,7 @@ int cg_set_attribute(const char *path, const char *attribute, const char *value)
|
||||
|
||||
assert(attribute);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, attribute, &p);
|
||||
r = cg_get_path(path, attribute, &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1482,7 +1479,7 @@ int cg_get_attribute(const char *path, const char *attribute, char **ret) {
|
||||
|
||||
assert(attribute);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, attribute, &p);
|
||||
r = cg_get_path(path, attribute, &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1535,7 +1532,7 @@ int cg_get_owner(const char *path, uid_t *ret_uid) {
|
||||
|
||||
assert(ret_uid);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &f);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &f);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1569,7 +1566,7 @@ int cg_get_keyed_attribute(
|
||||
*
|
||||
* If the attribute file doesn't exist at all returns ENOENT, if any key is not found returns ENXIO. */
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, attribute, &filename);
|
||||
r = cg_get_path(path, attribute, &filename);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1714,7 +1711,7 @@ int cg_mask_supported_subtree(const char *root, CGroupMask *ret) {
|
||||
|
||||
/* We can read the supported and accessible controllers from the top-level cgroup attribute */
|
||||
_cleanup_free_ char *controllers = NULL, *path = NULL;
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, root, "cgroup.controllers", &path);
|
||||
r = cg_get_path(root, "cgroup.controllers", &path);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -164,7 +164,7 @@ int cg_kill_recursive(const char *path, int sig, CGroupFlags flags, Set *killed_
|
||||
int cg_split_spec(const char *spec, char **ret_controller, char **ret_path);
|
||||
int cg_mangle_path(const char *path, char **ret);
|
||||
|
||||
int cg_get_path(const char *controller, const char *path, const char *suffix, char **ret);
|
||||
int cg_get_path(const char *path, const char *suffix, char **ret);
|
||||
|
||||
int cg_pid_get_path(pid_t pid, char **ret);
|
||||
int cg_pidref_get_path(const PidRef *pidref, char **ret);
|
||||
|
||||
@@ -2146,7 +2146,7 @@ int posix_spawn_wrapper(
|
||||
if (cgroup && have_clone_into_cgroup) {
|
||||
_cleanup_free_ char *resolved_cgroup = NULL;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, cgroup, /* suffix= */ NULL, &resolved_cgroup);
|
||||
r = cg_get_path(cgroup, /* suffix= */ NULL, &resolved_cgroup);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -172,7 +172,7 @@ static int process_memory(Group *g) {
|
||||
else {
|
||||
_cleanup_free_ char *p = NULL, *v = NULL;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, g->path, "memory.current", &p);
|
||||
r = cg_get_path(g->path, "memory.current", &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -202,7 +202,7 @@ static int process_io(Group *g, unsigned iteration) {
|
||||
|
||||
assert(g);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, g->path, "io.stat", &p);
|
||||
r = cg_get_path(g->path, "io.stat", &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -395,7 +395,7 @@ static int process(
|
||||
} else {
|
||||
_cleanup_free_ char *p = NULL, *v = NULL;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, "pids.current", &p);
|
||||
r = cg_get_path(path, "pids.current", &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -236,7 +236,7 @@ int bpf_devices_apply_policy(
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Extending device control BPF program failed: %m");
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, cgroup_path, NULL, &controller_path);
|
||||
r = cg_get_path(cgroup_path, /* suffix = */ NULL, &controller_path);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to determine cgroup path: %m");
|
||||
|
||||
|
||||
@@ -696,7 +696,7 @@ int bpf_firewall_install(Unit *u) {
|
||||
return log_unit_debug_errno(u, SYNTHETIC_ERRNO(EOPNOTSUPP),
|
||||
"bpf-firewall: BPF firewalling not supported, proceeding without.");
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, NULL, &path);
|
||||
r = cg_get_path(crt->cgroup_path, /* suffix = */ NULL, &path);
|
||||
if (r < 0)
|
||||
return log_unit_error_errno(u, r, "bpf-firewall: Failed to determine cgroup path: %m");
|
||||
|
||||
|
||||
@@ -151,7 +151,7 @@ int bpf_foreign_install(Unit *u) {
|
||||
if (!crt)
|
||||
return 0;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, NULL, &cgroup_path);
|
||||
r = cg_get_path(crt->cgroup_path, /* suffix = */ NULL, &cgroup_path);
|
||||
if (r < 0)
|
||||
return log_unit_error_errno(u, r, "bpf-foreign: Failed to get cgroup path: %m");
|
||||
|
||||
|
||||
@@ -115,7 +115,7 @@ static int restrict_ifaces_install_impl(Unit *u) {
|
||||
if (!crt)
|
||||
return 0;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, NULL, &cgroup_path);
|
||||
r = cg_get_path(crt->cgroup_path, /* suffix = */ NULL, &cgroup_path);
|
||||
if (r < 0)
|
||||
return log_unit_error_errno(u, r, "restrict-interfaces: Failed to get cgroup path: %m");
|
||||
|
||||
|
||||
@@ -179,7 +179,7 @@ static int socket_bind_install_impl(Unit *u) {
|
||||
if (!crt)
|
||||
return 0;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, NULL, &cgroup_path);
|
||||
r = cg_get_path(crt->cgroup_path, /* suffix = */ NULL, &cgroup_path);
|
||||
if (r < 0)
|
||||
return log_unit_error_errno(u, r, "bpf-socket-bind: Failed to get cgroup path: %m");
|
||||
|
||||
|
||||
@@ -1989,7 +1989,7 @@ static int unit_watch_cgroup(Unit *u) {
|
||||
if (r < 0)
|
||||
return log_oom();
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, "cgroup.events", &events);
|
||||
r = cg_get_path(crt->cgroup_path, "cgroup.events", &events);
|
||||
if (r < 0)
|
||||
return log_oom();
|
||||
|
||||
@@ -2044,7 +2044,7 @@ static int unit_watch_cgroup_memory(Unit *u) {
|
||||
if (r < 0)
|
||||
return log_oom();
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, "memory.events", &events);
|
||||
r = cg_get_path(crt->cgroup_path, "memory.events", &events);
|
||||
if (r < 0)
|
||||
return log_oom();
|
||||
|
||||
@@ -2103,7 +2103,7 @@ static int unit_update_cgroup(
|
||||
CGroupRuntime *crt = ASSERT_PTR(unit_get_cgroup_runtime(u));
|
||||
|
||||
uint64_t cgroup_id = 0;
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, NULL, &cgroup_full_path);
|
||||
r = cg_get_path(crt->cgroup_path, /* suffix = */ NULL, &cgroup_full_path);
|
||||
if (r == 0) {
|
||||
r = cg_path_get_cgroupid(cgroup_full_path, &cgroup_id);
|
||||
if (r < 0)
|
||||
@@ -3769,7 +3769,7 @@ static int unit_get_io_accounting_raw(
|
||||
if (!FLAGS_SET(crt->cgroup_realized_mask, CGROUP_MASK_IO))
|
||||
return -ENODATA;
|
||||
|
||||
r = cg_get_path("io", crt->cgroup_path, "io.stat", &path);
|
||||
r = cg_get_path(crt->cgroup_path, "io.stat", &path);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -4107,7 +4107,7 @@ int unit_cgroup_freezer_action(Unit *u, FreezerAction action) {
|
||||
assert_not_reached();
|
||||
}
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, crt->cgroup_path, "cgroup.freeze", &path);
|
||||
r = cg_get_path(crt->cgroup_path, "cgroup.freeze", &path);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -5579,7 +5579,7 @@ int exec_invoke(
|
||||
|
||||
if (is_pressure_supported() > 0) {
|
||||
if (cgroup_context_want_memory_pressure(cgroup_context)) {
|
||||
r = cg_get_path("memory", params->cgroup_path, "memory.pressure", &memory_pressure_path);
|
||||
r = cg_get_path(params->cgroup_path, "memory.pressure", &memory_pressure_path);
|
||||
if (r < 0) {
|
||||
*exit_status = EXIT_MEMORY;
|
||||
return log_oom();
|
||||
@@ -5597,7 +5597,7 @@ int exec_invoke(
|
||||
* memory_pressure_path != NULL in the conditional below. */
|
||||
if (memory_pressure_path && needs_sandboxing && exec_needs_cgroup_namespace(context)) {
|
||||
memory_pressure_path = mfree(memory_pressure_path);
|
||||
r = cg_get_path("memory", "/", "memory.pressure", &memory_pressure_path);
|
||||
r = cg_get_path("/", "memory.pressure", &memory_pressure_path);
|
||||
if (r < 0) {
|
||||
*exit_status = EXIT_MEMORY;
|
||||
return log_oom();
|
||||
|
||||
@@ -616,7 +616,7 @@ static int machine_watch_cgroup(Machine *m) {
|
||||
return 0;
|
||||
|
||||
_cleanup_free_ char *p = NULL;
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, m->cgroup, "cgroup.events", &p);
|
||||
r = cg_get_path(m->cgroup, "cgroup.events", &p);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to get cgroup path for cgroup '%s': %m", m->cgroup);
|
||||
|
||||
|
||||
@@ -113,7 +113,7 @@ int create_subcgroup(
|
||||
return log_error_errno(r, "Failed to add cgroup %s to userns: %m", payload);
|
||||
} else {
|
||||
_cleanup_free_ char *fs = NULL;
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, payload, NULL, &fs);
|
||||
r = cg_get_path(payload, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to get file system path for container cgroup: %m");
|
||||
|
||||
|
||||
@@ -240,7 +240,7 @@ int oomd_cgroup_kill(const char *path, bool recurse, bool dry_run) {
|
||||
if (dry_run) {
|
||||
_cleanup_free_ char *cg_path = NULL;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &cg_path);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &cg_path);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -418,7 +418,7 @@ int oomd_cgroup_context_acquire(const char *path, OomdCGroupContext **ret) {
|
||||
is_root = empty_or_root(path);
|
||||
ctx->preference = MANAGED_OOM_PREFERENCE_NONE;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, "memory.pressure", &p);
|
||||
r = cg_get_path(path, "memory.pressure", &p);
|
||||
if (r < 0)
|
||||
return log_debug_errno(r, "Error getting cgroup memory pressure path from %s: %m", path);
|
||||
|
||||
|
||||
@@ -78,7 +78,7 @@ int cg_trim(const char *path, bool delete_root) {
|
||||
_cleanup_free_ char *fs = NULL;
|
||||
int r;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -115,7 +115,7 @@ int cg_create(const char *path) {
|
||||
_cleanup_free_ char *fs = NULL;
|
||||
int r;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -140,7 +140,7 @@ int cg_attach(const char *path, pid_t pid) {
|
||||
assert(path);
|
||||
assert(pid >= 0);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, "cgroup.procs", &fs);
|
||||
r = cg_get_path(path, "cgroup.procs", &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -216,7 +216,7 @@ int cg_set_access(
|
||||
return 0;
|
||||
|
||||
/* Configure access to the cgroup itself */
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -289,7 +289,7 @@ int cg_set_access_recursive(
|
||||
if (!uid_is_valid(uid) && !gid_is_valid(gid))
|
||||
return 0;
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &fs);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -396,7 +396,7 @@ int cg_enable(
|
||||
return 0;
|
||||
}
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, p, "cgroup.subtree_control", &fs);
|
||||
r = cg_get_path(p, "cgroup.subtree_control", &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -313,7 +313,7 @@ int show_cgroup(const char *path,
|
||||
|
||||
assert(path);
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, path, NULL, &p);
|
||||
r = cg_get_path(path, /* suffix = */ NULL, &p);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -1110,7 +1110,7 @@ static int condition_test_psi(Condition *c, char **env) {
|
||||
free_and_replace(slice_path, slice_joined);
|
||||
}
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, slice_path, controller, &pressure_path);
|
||||
r = cg_get_path(slice_path, controller, &pressure_path);
|
||||
if (r < 0)
|
||||
return log_debug_errno(r, "Error getting cgroup pressure path from %s: %m", slice_path);
|
||||
|
||||
|
||||
@@ -275,7 +275,7 @@ int main(int argc, char *argv[]) {
|
||||
if (r < 0)
|
||||
return log_tests_skipped_errno(r, "Failed to prepare cgroup subtree");
|
||||
|
||||
r = cg_get_path(SYSTEMD_CGROUP_CONTROLLER, cgroup, NULL, &controller_path);
|
||||
r = cg_get_path(cgroup, /* suffix = */ NULL, &controller_path);
|
||||
ASSERT_OK(r);
|
||||
|
||||
_cleanup_(bpf_program_freep) BPFProgram *prog = NULL;
|
||||
|
||||
@@ -54,7 +54,7 @@ TEST(cg_create) {
|
||||
ASSERT_TRUE(path_equal(path, test_d));
|
||||
free(path);
|
||||
|
||||
ASSERT_OK_ZERO(cg_get_path(SYSTEMD_CGROUP_CONTROLLER, test_d, NULL, &path));
|
||||
ASSERT_OK_ZERO(cg_get_path(test_d, /* suffix = */ NULL, &path));
|
||||
log_debug("test_d: %s", path);
|
||||
ASSERT_TRUE(path_equal(path, strjoina("/sys/fs/cgroup", test_d)));
|
||||
free(path);
|
||||
|
||||
Reference in New Issue
Block a user