]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: let (*sigctxt).r9 return the correct register value on netbsd
authorTobias Klauser <tklauser@distanz.ch>
Tue, 21 Mar 2023 16:44:29 +0000 (17:44 +0100)
committerGopher Robot <gobot@golang.org>
Tue, 21 Mar 2023 18:51:53 +0000 (18:51 +0000)
Fixes #59152

Change-Id: I7f89e2b48db9ff120d7cd094b72ded865874e961
Reviewed-on: https://go-review.googlesource.com/c/go/+/478135
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Heschi Kreinick <heschi@google.com>
Reviewed-by: Benny Siegert <bsiegert@gmail.com>
src/runtime/signal_netbsd_amd64.go

index 67fe4377fd60e9d9872410119e1a3b3685ccc140..2112efea22ad4654c4c765504d74c86c97c14c4e 100644 (file)
@@ -26,7 +26,7 @@ func (c *sigctxt) rsi() uint64 { return c.regs().__gregs[_REG_RSI] }
 func (c *sigctxt) rbp() uint64 { return c.regs().__gregs[_REG_RBP] }
 func (c *sigctxt) rsp() uint64 { return c.regs().__gregs[_REG_RSP] }
 func (c *sigctxt) r8() uint64  { return c.regs().__gregs[_REG_R8] }
-func (c *sigctxt) r9() uint64  { return c.regs().__gregs[_REG_R8] }
+func (c *sigctxt) r9() uint64  { return c.regs().__gregs[_REG_R9] }
 func (c *sigctxt) r10() uint64 { return c.regs().__gregs[_REG_R10] }
 func (c *sigctxt) r11() uint64 { return c.regs().__gregs[_REG_R11] }
 func (c *sigctxt) r12() uint64 { return c.regs().__gregs[_REG_R12] }