diff options
author | Russ Cox <rsc@golang.org> | 2015-10-30 11:03:02 -0400 |
---|---|---|
committer | Russ Cox <rsc@golang.org> | 2015-10-30 18:43:44 +0000 |
commit | bf1de1b141b6354874780401d4525b3b5a1ff6d5 (patch) | |
tree | d1ae2462ea0f5821de431ad5d339e1bc98e1aa0e /src/runtime/signal_arm.go | |
parent | 845878a213e1db930e17a5c3108b215be5edbb20 (diff) | |
download | go-bf1de1b141b6354874780401d4525b3b5a1ff6d5.tar.gz go-bf1de1b141b6354874780401d4525b3b5a1ff6d5.zip |
runtime: introduce GOTRACEBACK=single, now the default
Abandon (but still support) the old numbering system.
GOTRACEBACK=none is old 0
GOTRACEBACK=single is the new behavior
GOTRACEBACK=all is old 1
GOTRACEBACK=system is old 2
GOTRACEBACK=crash is unchanged
See doc comment change in runtime1.go for details.
Filed #13107 to decide whether to change default back to GOTRACEBACK=all for Go 1.6 release.
If you run into programs where printing only the current goroutine omits
needed information, please add details in a comment on that issue.
Fixes #12366.
Change-Id: I82ca8b99b5d86dceb3f7102d38d2659d45dbe0db
Reviewed-on: https://go-review.googlesource.com/16512
Reviewed-by: Austin Clements <austin@google.com>
Diffstat (limited to 'src/runtime/signal_arm.go')
-rw-r--r-- | src/runtime/signal_arm.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/signal_arm.go b/src/runtime/signal_arm.go index 1b8a2f5277..c00e43d0c2 100644 --- a/src/runtime/signal_arm.go +++ b/src/runtime/signal_arm.go @@ -126,8 +126,8 @@ func sighandler(sig uint32, info *siginfo, ctxt unsafe.Pointer, gp *g) { } print("\n") - var docrash bool - if gotraceback(&docrash) > 0 { + level, _, docrash := gotraceback() + if level > 0 { goroutineheader(gp) tracebacktrap(uintptr(c.pc()), uintptr(c.sp()), uintptr(c.lr()), gp) if crashing > 0 && gp != _g_.m.curg && _g_.m.curg != nil && readgstatus(_g_.m.curg)&^_Gscan == _Grunning { |