Lock proc while accessing p_siglist, p_sigmask and p_sigignore

in nfs_sigintr().
This commit is contained in:
Tim J. Robbins 2003-02-15 08:25:57 +00:00
parent 7ae7a6c4f7
commit 1bdd8ae409

View File

@ -1239,11 +1239,15 @@ nfs_sigintr(struct nfsmount *nmp, struct nfsreq *rep, struct thread *td)
return (0);
p = td->td_proc;
PROC_LOCK(p);
tmpset = p->p_siglist;
SIGSETNAND(tmpset, p->p_sigmask);
SIGSETNAND(tmpset, p->p_sigignore);
if (SIGNOTEMPTY(p->p_siglist) && NFSINT_SIGMASK(tmpset))
if (SIGNOTEMPTY(p->p_siglist) && NFSINT_SIGMASK(tmpset)) {
PROC_UNLOCK(p);
return (EINTR);
}
PROC_UNLOCK(p);
return (0);
}