From 1a97a8aef5fae63d881ccc5dd5e52f382f2c278b Mon Sep 17 00:00:00 2001 From: Yorick Barbanneau Date: Tue, 16 Nov 2021 21:45:56 +0100 Subject: [PATCH] TD2 I.6 never exit fot testing purpose --- code/userprog/exception.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/userprog/exception.cc b/code/userprog/exception.cc index 7dc3e42..df7ca0e 100644 --- a/code/userprog/exception.cc +++ b/code/userprog/exception.cc @@ -131,6 +131,8 @@ ExceptionHandler (ExceptionType which) #ifdef CHANGED case SC_Exit: { + while (1) + currentThread->Yield(); int ret = machine->ReadRegister(4); printf("Exit code %d\n", ret); interrupt->Powerdown();