setsugid() touches p->p_flag so assert that the proc is locked.

This commit is contained in:
Alfred Perlstein 2002-06-18 22:41:35 +00:00
parent a835396035
commit f2102dadf9

View File

@ -1862,6 +1862,8 @@ setlogin(struct thread *td, struct setlogin_args *uap)
void
setsugid(struct proc *p)
{
PROC_LOCK_ASSERT(p, MA_OWNED);
p->p_flag |= P_SUGID;
if (!(p->p_pfsflags & PF_ISUGID))
p->p_stops = 0;