| 148 | } |
| 149 | |
| 150 | static int |
| 151 | reap_release(struct thread *td, struct proc *p) |
| 152 | { |
| 153 | |
| 154 | sx_assert(&proctree_lock, SX_XLOCKED); |
| 155 | if (p != curproc) |
| 156 | return (EPERM); |
| 157 | if (p == initproc) |
| 158 | return (EINVAL); |
| 159 | if ((p->p_treeflag & P_TREE_REAPER) == 0) |
| 160 | return (EINVAL); |
| 161 | reaper_abandon_children(p, false); |
| 162 | return (0); |
| 163 | } |
| 164 | |
| 165 | static int |
| 166 | reap_status(struct thread *td, struct proc *p, |
no test coverage detected