cgroup-util: drop handcrafted cg_is_empty(), always check cgroup.events populated field
This effectively renames cg_is_empty_recursive() to cg_is_empty(). Note that all existing code calls the former and not the latter, hence with cgv1 support being dropped it's trivial to consult cgroup.events directly for populated state everywhere. Additionally, use more generic cg_get_keyed_attribute() helper rather than cg_read_event().
This commit is contained in:
@@ -233,7 +233,6 @@ int cg_get_xattr_bool(const char *path, const char *name);
|
||||
int cg_remove_xattr(const char *path, const char *name);
|
||||
|
||||
int cg_is_empty(const char *controller, const char *path);
|
||||
int cg_is_empty_recursive(const char *controller, const char *path);
|
||||
|
||||
int cg_get_root_path(char **path);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user