[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 5/7] proc: Fix miscalculation of count
From: |
Justus Winter |
Subject: |
[PATCH 5/7] proc: Fix miscalculation of count |
Date: |
Wed, 24 Jul 2013 08:30:57 +0200 |
* proc/pgrp.c (S_proc_getpgrppids): Fix miscalculation of count.
---
proc/pgrp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/proc/pgrp.c b/proc/pgrp.c
index 3b5dba1..403de97 100644
--- a/proc/pgrp.c
+++ b/proc/pgrp.c
@@ -265,7 +265,7 @@ S_proc_getpgrppids (struct proc *callerp,
count = 0;
for (p = pg->pg_plist; p; p = p->p_gnext)
- if (++count <= npids && !p->p_essential)
+ if (!p->p_essential && ++count <= npids)
*pp++ = p->p_pid;
if (count > npids)
--
1.7.10.4
- Re: /hurd/init and /hurd/proc, Samuel Thibault, 2013/07/15
- Re: /hurd/init and /hurd/proc, Roland McGrath, 2013/07/15
- kill (0, SIGSTOP) is freezing the system (was: /hurd/init and /hurd/proc), Justus Winter, 2013/07/24
- [PATCH 2/7] hurd: add proc_mark_essential, Justus Winter, 2013/07/24
- [PATCH 1/7] proc: add proc_mark_essential server code, Justus Winter, 2013/07/24
- [PATCH 4/7] init: Build fixes, Justus Winter, 2013/07/24
- [PATCH 3/7] init: Mark auth, proc and fs servers as essential, Justus Winter, 2013/07/24
- [PATCH 6/7] proc: evil hack, mark all pids<100 essential, Justus Winter, 2013/07/24
- [PATCH 5/7] proc: Fix miscalculation of count,
Justus Winter <=
- Re: kill (0, SIGSTOP) is freezing the system (was: /hurd/init and /hurd/proc), Samuel Thibault, 2013/07/24