summaryrefslogtreecommitdiff
path: root/proc
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1995-06-27 16:02:41 +0000
committerMichael I. Bushnell <mib@gnu.org>1995-06-27 16:02:41 +0000
commitfabe2864f56c2050f7e28a988f79a1354cb2691f (patch)
tree5d0dd38b60a834f502373355b1a586e11a87ed9d /proc
parent3c5b491408cdaa7c046e2d658b78d34bfad1040f (diff)
(S_proc_dostop): Remove assigments from inside if tests.
Diffstat (limited to 'proc')
-rw-r--r--proc/mgt.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/proc/mgt.c b/proc/mgt.c
index 26b86f91..7f9e5f3c 100644
--- a/proc/mgt.c
+++ b/proc/mgt.c
@@ -301,9 +301,11 @@ S_proc_dostop (struct proc *p,
unsigned int nthreads = 2, i;
error_t err;
- if (err = task_suspend (p->p_task))
+ err = task_suspend (p->p_task);
+ if (err)
return err;
- if (err = task_threads (p->p_task, &threads, &nthreads))
+ err = task_threads (p->p_task, &threads, &nthreads);
+ if (err)
return err;
for (i = 0; i < nthreads; i++)
{
@@ -314,7 +316,8 @@ S_proc_dostop (struct proc *p,
if (threads != threadbuf)
vm_deallocate (mach_task_self (), (vm_address_t) threads,
nthreads * sizeof (thread_t));
- if (err = task_resume (p->p_task))
+ err = task_resume (p->p_task);
+ if (err)
return err;
mach_port_deallocate (mach_task_self (), contthread);