Require p_cansched() for changing a process' protection status via
procctl() rather than p_cansee(). Submitted by: rwatson MFC after: 3 days
This commit is contained in:
parent
4f7bf7a846
commit
7aa1071e48
@ -1240,7 +1240,7 @@ protect_setchild(struct thread *td, struct proc *p, int flags)
|
||||
{
|
||||
|
||||
PROC_LOCK_ASSERT(p, MA_OWNED);
|
||||
if (p->p_flag & P_SYSTEM || p_cansee(td, p) != 0)
|
||||
if (p->p_flag & P_SYSTEM || p_cansched(td, p) != 0)
|
||||
return (0);
|
||||
if (flags & PPROT_SET) {
|
||||
p->p_flag |= P_PROTECTED;
|
||||
|
Loading…
x
Reference in New Issue
Block a user