summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_shutdown.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/kern_shutdown.c')
-rw-r--r--sys/kern/kern_shutdown.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/kern_shutdown.c b/sys/kern/kern_shutdown.c
index 209c22e..13a9c7a 100644
--- a/sys/kern/kern_shutdown.c
+++ b/sys/kern/kern_shutdown.c
@@ -433,6 +433,7 @@ static u_int panic_cpu = NOCPU;
void
panic(const char *fmt, ...)
{
+ struct thread *td = curthread;
int bootopt;
va_list ap;
static char buf[256];
@@ -486,6 +487,7 @@ panic(const char *fmt, ...)
}
#endif
#endif
+ td->td_flags |= TDF_INPANIC;
if (!sync_on_panic)
bootopt |= RB_NOSYNC;
boot(bootopt);
OpenPOWER on IntegriCloud