summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/kern/vfs_subr.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c
index eefc687..6a65680 100644
--- a/sys/kern/vfs_subr.c
+++ b/sys/kern/vfs_subr.c
@@ -2657,10 +2657,8 @@ vfs_unmountall()
struct thread *td;
int error;
- if (curthread != NULL)
- td = curthread;
- else
- td = FIRST_THREAD_IN_PROC(initproc); /* XXX XXX proc0? */
+ KASSERT(curthread != NULL, ("vfs_unmountall: NULL curthread"));
+ td = curthread;
/*
* Since this only runs when rebooting, it is not interlocked.
*/
OpenPOWER on IntegriCloud