mirror of
https://github.com/troglobit/finit.git
synced 2026-10-28 12:30:44 +00:00
cgroup: allow adding self (PID 0) to a leaf group
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
b921b8cf0f
commit
f12f53692e
2 files changed
+2
-2
No files matched your search
+1
-1
@@ -139,7 +139,7 @@ static int cgroup_leaf_init(char *group, char *name, int pid, const char *cfg)
|
||||
char path[256];
|
||||
|
||||
_d("group %s, name %s, pid %d, cfg %s", group, name, pid, cfg ?: "NIL");
|
||||
if (pid <= 1) {
|
||||
if (pid < 0 || pid == 1) {
|
||||
errno = EINVAL;
|
||||
return 1;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user