Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 176337
b: refs/heads/master
c: dfc6a73
h: refs/heads/master
i:
  176335: fbf8e63
v: v3
  • Loading branch information
H Hartley Sweeten authored and Linus Torvalds committed Dec 15, 2009
1 parent e1ffb9a commit 3f8f0d4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 948c1e2521979c332b21b623414cf258150f214e
refs/heads/master: dfc6a736d452a8c308190b618b065c2257d370ff
8 changes: 4 additions & 4 deletions trunk/kernel/sys.c
Original file line number Diff line number Diff line change
Expand Up @@ -189,10 +189,10 @@ SYSCALL_DEFINE3(setpriority, int, which, int, who, int, niceval)
!(user = find_user(who)))
goto out_unlock; /* No processes for this user */

do_each_thread(g, p)
do_each_thread(g, p) {
if (__task_cred(p)->uid == who)
error = set_one_prio(p, niceval, error);
while_each_thread(g, p);
} while_each_thread(g, p);
if (who != cred->uid)
free_uid(user); /* For find_user() */
break;
Expand Down Expand Up @@ -252,13 +252,13 @@ SYSCALL_DEFINE2(getpriority, int, which, int, who)
!(user = find_user(who)))
goto out_unlock; /* No processes for this user */

do_each_thread(g, p)
do_each_thread(g, p) {
if (__task_cred(p)->uid == who) {
niceval = 20 - task_nice(p);
if (niceval > retval)
retval = niceval;
}
while_each_thread(g, p);
} while_each_thread(g, p);
if (who != cred->uid)
free_uid(user); /* for find_user() */
break;
Expand Down

0 comments on commit 3f8f0d4

Please sign in to comment.