summaryrefslogtreecommitdiffstats
path: root/sys/fs/procfs/procfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/fs/procfs/procfs.c')
-rw-r--r--sys/fs/procfs/procfs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/fs/procfs/procfs.c b/sys/fs/procfs/procfs.c
index b950b58..309f0f2 100644
--- a/sys/fs/procfs/procfs.c
+++ b/sys/fs/procfs/procfs.c
@@ -70,7 +70,9 @@ procfs_doprocfile(PFS_FILL_ARGS)
char *fullpath = "unknown";
char *freepath = NULL;
+ vn_lock(p->p_textvp, LK_EXCLUSIVE | LK_RETRY, td);
vn_fullpath(td, p->p_textvp, &fullpath, &freepath);
+ VOP_UNLOCK(p->p_textvp, 0, td);
sbuf_printf(sb, "%s", fullpath);
if (freepath)
free(freepath, M_TEMP);
OpenPOWER on IntegriCloud