diff options
| author | Michael Pratt <mpratt@google.com> | 2022-07-14 17:36:59 -0400 |
|---|---|---|
| committer | Michael Pratt <mpratt@google.com> | 2022-08-12 01:38:55 +0000 |
| commit | bd302502d39b6172bf3db6abfa49fdcaa124ee50 (patch) | |
| tree | 3b5ad6d467a4f529f8416d6989c880a7f28d27d7 /src/runtime/traceback.go | |
| parent | 7666ec1c99b2f8c88b42fb5462510cafce120a6f (diff) | |
| download | go-bd302502d39b6172bf3db6abfa49fdcaa124ee50.tar.xz | |
runtime: convert panicking to atomic type
For #53821.
Change-Id: I93409f377881a3c029b41b0f1fbcef5e21091f2f
Reviewed-on: https://go-review.googlesource.com/c/go/+/419438
Reviewed-by: Austin Clements <austin@google.com>
Run-TryBot: Michael Pratt <mpratt@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Diffstat (limited to 'src/runtime/traceback.go')
| -rw-r--r-- | src/runtime/traceback.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/traceback.go b/src/runtime/traceback.go index 6df0bbfabe..96cf82c23e 100644 --- a/src/runtime/traceback.go +++ b/src/runtime/traceback.go @@ -1407,7 +1407,7 @@ func printOneCgoTraceback(pc uintptr, max int, arg *cgoSymbolizerArg) int { // callCgoSymbolizer calls the cgoSymbolizer function. func callCgoSymbolizer(arg *cgoSymbolizerArg) { call := cgocall - if panicking > 0 || getg().m.curg != getg() { + if panicking.Load() > 0 || getg().m.curg != getg() { // We do not want to call into the scheduler when panicking // or when on the system stack. call = asmcgocall @@ -1427,7 +1427,7 @@ func cgoContextPCs(ctxt uintptr, buf []uintptr) { return } call := cgocall - if panicking > 0 || getg().m.curg != getg() { + if panicking.Load() > 0 || getg().m.curg != getg() { // We do not want to call into the scheduler when panicking // or when on the system stack. call = asmcgocall |
