diff options
Diffstat (limited to 'kernel/trap.c')
-rw-r--r-- | kernel/trap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/trap.c b/kernel/trap.c index ec57bed..e96a542 100644 --- a/kernel/trap.c +++ b/kernel/trap.c @@ -54,7 +54,7 @@ usertrap(void) // system call if(p->killed) - exit(); + exit(-1); // sepc points to the ecall instruction, // but we want to return to the next instruction. @@ -74,7 +74,7 @@ usertrap(void) } if(p->killed) - exit(); + exit(-1); // give up the CPU if this is a timer interrupt. if(which_dev == 2) |