summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/fs/procfs/procfs_vnops.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/fs/procfs/procfs_vnops.c b/sys/fs/procfs/procfs_vnops.c
index 5367078..d9a5f57 100644
--- a/sys/fs/procfs/procfs_vnops.c
+++ b/sys/fs/procfs/procfs_vnops.c
@@ -741,7 +741,7 @@ procfs_validfile(td)
struct thread *td;
{
- return (procfs_findtextvp(td->td_proc) != NULLVP);
+ return (td->td_proc->p_textvp != NULLVP);
}
/*
@@ -816,8 +816,10 @@ procfs_readdir(ap)
bcopy(pt->pt_name, dp->d_name, pt->pt_namlen + 1);
dp->d_type = pt->pt_type;
+ PROC_UNLOCK(p);
if ((error = uiomove((caddr_t)dp, delen, uio)) != 0)
break;
+ PROC_LOCK(p);
}
PROC_UNLOCK(p);
OpenPOWER on IntegriCloud