Drop the proc lock around SYSCTL_OUT in the no-threads case.

Submitted by:	truckman
This commit is contained in:
Scott Long 2003-06-17 19:14:00 +00:00
parent 1ebb6f8748
commit 04d2f20f6b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=116498

View file

@ -860,8 +860,10 @@ sysctl_out_proc(struct proc *p, struct sysctl_req *req, int flags)
if (flags & KERN_PROC_NOTHREADS) {
fill_kinfo_proc(p, &kinfo_proc);
PROC_UNLOCK(p);
error = SYSCTL_OUT(req, (caddr_t)&kinfo_proc,
sizeof(kinfo_proc));
PROC_LOCK(p);
} else {
_PHOLD(p);
FOREACH_THREAD_IN_PROC(p, td) {