cgroup-util: move Set* allocation into cg_kernel_controllers()
Previously, callers had to do this on their own. Let's make the call do that instead, making the caller code a bit shorter.
This commit is contained in:
@@ -1111,11 +1111,7 @@ static int mount_legacy_cgns_unsupported(
|
||||
if (r > 0)
|
||||
goto skip_controllers;
|
||||
|
||||
controllers = set_new(&string_hash_ops);
|
||||
if (!controllers)
|
||||
return log_oom();
|
||||
|
||||
r = cg_kernel_controllers(controllers);
|
||||
r = cg_kernel_controllers(&controllers);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to determine cgroup controllers: %m");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user