summaryrefslogtreecommitdiff
path: root/kernel/capability.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/capability.c')
-rw-r--r--kernel/capability.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/capability.c b/kernel/capability.c
index 1c5c35718450..7e864e2ccf6a 100644
--- a/kernel/capability.c
+++ b/kernel/capability.c
@@ -89,14 +89,12 @@ static inline void cap_set_pg(int pgrp, kernel_cap_t *effective,
kernel_cap_t *permitted)
{
task_t *g, *target;
- struct list_head *l;
- struct pid *pid;
- for_each_task_pid(pgrp, PIDTYPE_PGID, g, l, pid) {
+ do_each_task_pid(pgrp, PIDTYPE_PGID, g) {
target = g;
while_each_thread(g, target)
security_capset_set(target, effective, inheritable, permitted);
- }
+ } while_each_task_pid(pgrp, PIDTYPE_PGID, g);
}
/*