diff options
author | rsc <rsc> | 2007-08-08 08:38:11 +0000 |
---|---|---|
committer | rsc <rsc> | 2007-08-08 08:38:11 +0000 |
commit | 7366e042d9a7a21397115ca49c0d9344a9365ada (patch) | |
tree | b7012b4ddb0dfbb292fe62c23bdaecb1f2616b83 /trap.c | |
parent | 7e89fb90bd0beb91e5d67af362d6a8a3a1b4c626 (diff) | |
download | xv6-labs-7366e042d9a7a21397115ca49c0d9344a9365ada.tar.gz xv6-labs-7366e042d9a7a21397115ca49c0d9344a9365ada.tar.bz2 xv6-labs-7366e042d9a7a21397115ca49c0d9344a9365ada.zip |
save process name for debugging
Diffstat (limited to 'trap.c')
-rw-r--r-- | trap.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -80,10 +80,10 @@ trap(struct trapframe *tf) break; default: - if(curproc[cpu()]) { + if(cp) { // Assume process divided by zero or dereferenced null, etc. - cprintf("pid %d: unhandled trap %d on cpu %d eip %x -- kill proc\n", - curproc[cpu()]->pid, v, cpu(), tf->eip); + cprintf("pid %d %s: unhandled trap %d on cpu %d eip %x -- kill proc\n", + cp->pid, cp->name, v, cpu(), tf->eip); proc_exit(); } |