vx32

Local 9vx git repository for patches.
git clone git://r-36.net/vx32
Log | Files | Refs

commit 10ce51eb5efc3595711c6f7f8f5372641cb4e610
parent 6bd3e819222bb75d9613437be31dece1130579fe
Author: Russ Cox <rsc@swtch.com>
Date:   Thu, 31 Jul 2008 15:22:10 -0400

9vx: use different flag for abort-on-fault

Diffstat:
src/9vx/main.c | 4++++
src/9vx/vx32.c | 3++-
2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/9vx/main.c b/src/9vx/main.c @@ -37,6 +37,7 @@ extern Dev fsdevtab; extern Dev audiodevtab; int doabort = 1; // for now +int abortonfault; char* argv0; char* conffile = "9vx"; Conf conf; @@ -95,6 +96,9 @@ main(int argc, char **argv) case 'A': doabort++; break; + case 'B': + abortonfault++; + break; case 'K': tracekdev++; break; diff --git a/src/9vx/vx32.c b/src/9vx/vx32.c @@ -32,6 +32,7 @@ enum { int nfaults; int traceprocs; int tracesyscalls; +extern int abortonfault; extern char *sysctab[]; extern void mathemu(Ureg*, void*); @@ -276,7 +277,7 @@ touser(void *initsp) addr - up->pmmu.uzero, vp->cpu->trapva, vp->cpu->eip); proc2ureg(vp, &u); dumpregs(&u); - if(doabort) + if(abortonfault) abort(); }