proc: Fix buggy disowning of children
authorBarret Rhoden <brho@cs.berkeley.edu>
Tue, 13 Mar 2018 23:29:07 +0000 (19:29 -0400)
committerBarret Rhoden <brho@cs.berkeley.edu>
Wed, 28 Mar 2018 20:43:05 +0000 (16:43 -0400)
commitf90eea80a2fc0c8a1d316c9d4590e9a7de7b8820
tree85eb428af70b754e4a4c040e9b06b01ac7dd9a2b
parentc7f5380a2941e605d2226202ed2f8b368a681fa9
proc: Fix buggy disowning of children

Two things: it was decreffing while holding a spinlock and it was
holding the wrong spinlock.  The process's children list is protected by
the 'child_wait' lock, not the overall proc lock.

Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
kern/src/process.c