aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/kern_exit.c
diff options
context:
space:
mode:
authorBrian Feldman <green@FreeBSD.org>2004-03-18 18:15:58 +0000
committerBrian Feldman <green@FreeBSD.org>2004-03-18 18:15:58 +0000
commit150883179a1210fd011d690db9b08cd9a3bc4fb2 (patch)
tree5fd3a0401e5b361aa544822722ecd245ef82ceec /sys/kern/kern_exit.c
parent8bbf57a9c8504ed88c04b5bca7503d635473be05 (diff)
downloadsrc-150883179a1210fd011d690db9b08cd9a3bc4fb2.tar.gz
src-150883179a1210fd011d690db9b08cd9a3bc4fb2.zip
Add the missing Giant when doing anything with VFS -- in this case,
releasing the ktrace vnode.
Notes
Notes: svn path=/head/; revision=127181
Diffstat (limited to 'sys/kern/kern_exit.c')
-rw-r--r--sys/kern/kern_exit.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c
index 5f37ca63c7c7..8c82e42ea3a8 100644
--- a/sys/kern/kern_exit.c
+++ b/sys/kern/kern_exit.c
@@ -367,8 +367,11 @@ exit1(struct thread *td, int rv)
p->p_tracecred = NULL;
mtx_unlock(&ktrace_mtx);
PROC_UNLOCK(p);
- if (tracevp != NULL)
+ if (tracevp != NULL) {
+ mtx_lock(&Giant);
vrele(tracevp);
+ mtx_unlock(&Giant);
+ }
if (tracecred != NULL)
crfree(tracecred);
#endif