From 29b9a328d268d53833d2cc063d1d8b4bf6852675 Mon Sep 17 00:00:00 2001 From: Michael Pratt Date: Wed, 20 Jul 2022 13:18:06 -0400 Subject: runtime: trivial replacements of g in remaining files Rename g variables to gp for consistency. Change-Id: I09ecdc7e8439637bc0e32f9c5f96f515e6436362 Reviewed-on: https://go-review.googlesource.com/c/go/+/418591 Reviewed-by: Austin Clements Run-TryBot: Michael Pratt --- src/runtime/cgocheck.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/runtime/cgocheck.go') diff --git a/src/runtime/cgocheck.go b/src/runtime/cgocheck.go index 74a2ec09bc..6b492093ea 100644 --- a/src/runtime/cgocheck.go +++ b/src/runtime/cgocheck.go @@ -32,14 +32,14 @@ func cgoCheckWriteBarrier(dst *uintptr, src uintptr) { // If we are running on the system stack then dst might be an // address on the stack, which is OK. - g := getg() - if g == g.m.g0 || g == g.m.gsignal { + gp := getg() + if gp == gp.m.g0 || gp == gp.m.gsignal { return } // Allocating memory can write to various mfixalloc structs // that look like they are non-Go memory. - if g.m.mallocing != 0 { + if gp.m.mallocing != 0 { return } -- cgit v1.2.1