diff options
| author | cinap_lenrek <cinap_lenrek@felloff.net> | 2019-01-22 21:55:20 +0100 |
|---|---|---|
| committer | cinap_lenrek <cinap_lenrek@felloff.net> | 2019-01-22 21:55:20 +0100 |
| commit | 4b2f31131adaec9bd2837d877c4732069db27999 (patch) | |
| tree | 60c15abe654b2a3eb8d5ff76f495e963027be475 | |
| parent | 927e342aca77bd5a1c3752e54b2385f6bb1c2208 (diff) | |
| download | plan9front-4b2f31131adaec9bd2837d877c4732069db27999.tar.xz | |
pc64: properly handle faulterror in faultamd64()
replicate what faulterror() would have done with up->nerrlab == 0,
that is, terminate the process.
| -rw-r--r-- | sys/src/9/pc64/trap.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/src/9/pc64/trap.c b/sys/src/9/pc64/trap.c index 23c1e9b69..f1db63c23 100644 --- a/sys/src/9/pc64/trap.c +++ b/sys/src/9/pc64/trap.c @@ -698,6 +698,10 @@ faultamd64(Ureg* ureg, void*) up->insyscall = 1; f = fpusave(); if(!user && waserror()){ + if(up->nerrlab == 0){ + pprint("suicide: sys: %s\n", up->errstr); + pexit(up->errstr, 1); + } int s = splhi(); fpurestore(f); up->insyscall = insyscall; |
