From 24ce56cccb6f179f8c6ed9ad82e6afb871aabf80 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Tue, 8 Jun 2021 21:13:33 +0200 Subject: Process exit improvements --- kernel/drivers/int.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'kernel/drivers') diff --git a/kernel/drivers/int.c b/kernel/drivers/int.c index 39462fa..f6a5134 100644 --- a/kernel/drivers/int.c +++ b/kernel/drivers/int.c @@ -109,12 +109,16 @@ static void int_trap_handler(struct int_frame *frame) frame->eip, frame->eip - proc->entry); printf("\t\t-> Process: [entry: %x, kstack: %x, esp %x, ustack: %x]\n", proc->entry, proc->stack.kernel, frame->esp, proc->stack.user); + faulting--; - proc_exit(proc, 1); + proc_exit(1); } else { + print_trace(); while (1) __asm__ volatile("cli\nhlt"); } + + assert_not_reached(); } /** -- cgit v1.2.3