diff options
| author | Jes Cok <xigua67damn@gmail.com> | 2023-09-16 00:07:59 +0000 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2023-09-20 18:20:42 +0000 |
| commit | a72d1e5bf4eedec97dbc79bce3b5dc8a76c1b2ac (patch) | |
| tree | 6ddf892b80838aebf35ba91f42b710d984c2c50d | |
| parent | 6f2e1be1320940ffce998011ee2d81190cec8bca (diff) | |
| download | go-a72d1e5bf4eedec97dbc79bce3b5dc8a76c1b2ac.tar.xz | |
runtime: unify the method signature for *sigctxt.fault
Currently, *sigctxt.fault of freebsd-arm64 and openbsd-arm64 return
uint64 which is different from other arches (return uintptr). Change
the method signature for consistency.
Change-Id: I81185123c1ea40e456075fd86b931aa860c38a42
GitHub-Last-Rev: 82934ecd3d2c712c2f47378e5b2c802427874d4d
GitHub-Pull-Request: golang/go#62672
Reviewed-on: https://go-review.googlesource.com/c/go/+/528817
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
| -rw-r--r-- | src/runtime/signal_freebsd_arm64.go | 2 | ||||
| -rw-r--r-- | src/runtime/signal_openbsd_arm64.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/signal_freebsd_arm64.go b/src/runtime/signal_freebsd_arm64.go index 159e965a7d..2b87369815 100644 --- a/src/runtime/signal_freebsd_arm64.go +++ b/src/runtime/signal_freebsd_arm64.go @@ -52,7 +52,7 @@ func (c *sigctxt) sp() uint64 { return c.regs().mc_gpregs.gp_sp } //go:nowritebarrierrec func (c *sigctxt) pc() uint64 { return c.regs().mc_gpregs.gp_elr } -func (c *sigctxt) fault() uint64 { return c.info.si_addr } +func (c *sigctxt) fault() uintptr { return uintptr(c.info.si_addr) } func (c *sigctxt) sigcode() uint64 { return uint64(c.info.si_code) } func (c *sigctxt) sigaddr() uint64 { return c.info.si_addr } diff --git a/src/runtime/signal_openbsd_arm64.go b/src/runtime/signal_openbsd_arm64.go index 3747b4f91b..bb14c8d6f3 100644 --- a/src/runtime/signal_openbsd_arm64.go +++ b/src/runtime/signal_openbsd_arm64.go @@ -54,7 +54,7 @@ func (c *sigctxt) sp() uint64 { return (uint64)(c.regs().sc_sp) } //go:nowritebarrierrec func (c *sigctxt) rip() uint64 { return (uint64)(c.regs().sc_lr) } /* XXX */ -func (c *sigctxt) fault() uint64 { return c.sigaddr() } +func (c *sigctxt) fault() uintptr { return uintptr(c.sigaddr()) } func (c *sigctxt) sigcode() uint64 { return uint64(c.info.si_code) } func (c *sigctxt) sigaddr() uint64 { return *(*uint64)(add(unsafe.Pointer(c.info), 16)) |
