cgroup-util: Ignore kernel threads in cg_kill_items()
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 30 Jul 2024 09:53:32 +0000 (11:53 +0200)
committerLuca Boccassi <bluca@debian.org>
Thu, 15 Aug 2024 12:08:37 +0000 (13:08 +0100)
commit3d90344e941f10b6fe7b1a315b79ca09c4451a86
tree0e670c76198ed34d32018299ca7fcc9554129711
parent1cb21b2cb194501464c52c1f32ae55f593689cc3
cgroup-util: Ignore kernel threads in cg_kill_items()

Similar to the implementation of cgroup.kill in the kernel, let's
skip kernel threads in cg_kill_items() as trying to kill kernel
threads as an unprivileged process will fail with EPERM and doesn't
do anything when running privileged.

(cherry picked from commit 0fbb569de1dcc06118dba006cf7a40caf6cd94d0)
src/basic/cgroup-util.c