mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-08 21:17:47 +03:00
cgroup-util: laccess() returns negative errno already
This commit is contained in:
parent
12a9f68f06
commit
cb3763d57b
@ -587,10 +587,7 @@ static int controller_is_v1_accessible(const char *root, const char *controller)
|
||||
* - we can modify the hierarchy. */
|
||||
|
||||
cpath = strjoina("/sys/fs/cgroup/", dn, root, root ? "/cgroup.procs" : NULL);
|
||||
if (laccess(cpath, root ? W_OK : F_OK) < 0)
|
||||
return -errno;
|
||||
|
||||
return 0;
|
||||
return laccess(cpath, root ? W_OK : F_OK);
|
||||
}
|
||||
|
||||
int cg_get_path_and_check(const char *controller, const char *path, const char *suffix, char **fs) {
|
||||
|
Loading…
Reference in New Issue
Block a user