diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2021-04-21 12:24:27 +0200 |
---|---|---|
committer | Tobias Klauser <tobias.klauser@gmail.com> | 2021-04-21 15:57:05 +0000 |
commit | f9e2dbbfc92fdc19c4e9412b318beb5294d91bff (patch) | |
tree | 09afa26dc22b9e99025c0543322eae3786103c4b /src/syscall | |
parent | e5bc4f2a77e497f30dce08014bc6addd8a7d9982 (diff) | |
download | go-f9e2dbbfc92fdc19c4e9412b318beb5294d91bff.tar.gz go-f9e2dbbfc92fdc19c4e9412b318beb5294d91bff.zip |
syscall: use libc in Exec on openbsd/arm64
Like on openbsd/amd64, use libc instead of direct syscalls on
openbsd/arm64.
This was likely missed in CL 286815. A similar change was done for
openbsd/amd64 in CL 270380.
Updates #36435
Change-Id: Ie496a6130f1a43d30974502777db12217e65c551
Reviewed-on: https://go-review.googlesource.com/c/go/+/312229
Trust: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Joel Sing <joel@sing.id.au>
Diffstat (limited to 'src/syscall')
-rw-r--r-- | src/syscall/exec_unix.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/syscall/exec_unix.go b/src/syscall/exec_unix.go index 1f38de22b2..64a5b61fe5 100644 --- a/src/syscall/exec_unix.go +++ b/src/syscall/exec_unix.go @@ -301,7 +301,7 @@ func Exec(argv0 string, argv []string, envv []string) (err error) { } else if runtime.GOOS == "darwin" || runtime.GOOS == "ios" { // Similarly on Darwin. err1 = execveDarwin(argv0p, &argvp[0], &envvp[0]) - } else if runtime.GOOS == "openbsd" && runtime.GOARCH == "amd64" { + } else if runtime.GOOS == "openbsd" && (runtime.GOARCH == "amd64" || runtime.GOARCH == "arm64") { // Similarly on OpenBSD. err1 = execveOpenBSD(argv0p, &argvp[0], &envvp[0]) } else { |